helper

package
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 25, 2022 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ApplyReplica

func ApplyReplica(workload *unstructured.Unstructured, desireReplica int64, field string) error

ApplyReplica applies the Replica value for the specific field.

func ConvertToDaemonSet

func ConvertToDaemonSet(obj *unstructured.Unstructured) (*appsv1.DaemonSet, error)

ConvertToDaemonSet converts a DaemonSet object from unstructured to typed.

func ConvertToDeployment

func ConvertToDeployment(obj *unstructured.Unstructured) (*appsv1.Deployment, error)

ConvertToDeployment converts a Deployment object from unstructured to typed.

func ConvertToEndpointSlice

func ConvertToEndpointSlice(obj *unstructured.Unstructured) (*discoveryv1.EndpointSlice, error)

ConvertToEndpointSlice converts a EndpointSlice object from unstructured to typed.

func ConvertToIngress

func ConvertToIngress(obj *unstructured.Unstructured) (*extensionsv1beta1.Ingress, error)

ConvertToIngress converts a Service object from unstructured to typed.

func ConvertToJob

func ConvertToJob(obj *unstructured.Unstructured) (*batchv1.Job, error)

ConvertToJob converts a Job object from unstructured to typed.

func ConvertToNode

func ConvertToNode(obj *unstructured.Unstructured) (*corev1.Node, error)

ConvertToNode converts a Node object from unstructured to typed.

func ConvertToPod

func ConvertToPod(obj *unstructured.Unstructured) (*corev1.Pod, error)

ConvertToPod converts a Pod object from unstructured to typed.

func ConvertToReplicaSet

func ConvertToReplicaSet(obj *unstructured.Unstructured) (*appsv1.ReplicaSet, error)

ConvertToReplicaSet converts a ReplicaSet object from unstructured to typed.

func ConvertToService

func ConvertToService(obj *unstructured.Unstructured) (*corev1.Service, error)

ConvertToService converts a Service object from unstructured to typed.

func ConvertToStatefulSet

func ConvertToStatefulSet(obj *unstructured.Unstructured) (*appsv1.StatefulSet, error)

ConvertToStatefulSet converts a StatefulSet object from unstructured to typed.

func ToUnstructured

func ToUnstructured(obj interface{}) (*unstructured.Unstructured, error)

ToUnstructured converts a typed object to an unstructured object.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL