getter

package
v1.13.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetConfigMap

func GetConfigMap(ns, name string, cl client.Client) (*corev1.ConfigMap, bool, error)

func GetConfigMapYaml added in v1.9.9

func GetConfigMapYaml(ns string, name string, cl client.Client) ([]byte, bool, error)

func GetConfigMapYamlFormat added in v1.9.9

func GetConfigMapYamlFormat(ns string, name string, cl client.Client) ([]byte, bool, error)

func GetDeployment

func GetDeployment(ns, name string, cl client.Client) (*appsv1.Deployment, bool, error)

func GetDeploymentYaml added in v1.5.0

func GetDeploymentYaml(ns string, name string, cl client.Client) ([]byte, bool, error)

func GetDeploymentYamlFormat added in v1.9.9

func GetDeploymentYamlFormat(ns string, name string, cl client.Client) ([]byte, bool, error)

func GetExtensionsV1Beta1Ingress added in v1.9.9

func GetExtensionsV1Beta1Ingress(namespace, name string, lister informers.SharedInformerFactory) (*extensionsv1beta1.Ingress, bool, error)

func GetIngressYaml added in v1.9.9

func GetIngressYaml(ns string, name string, cl client.Client) ([]byte, bool, error)

func GetIngressYamlFormat added in v1.9.9

func GetIngressYamlFormat(ns string, name string, cl client.Client) ([]byte, bool, error)

func GetJob

func GetJob(ns, name string, cl client.Client) (*batchv1.Job, bool, error)

func GetNamespace

func GetNamespace(ns string, cl client.Client) (*corev1.Namespace, bool, error)

func GetNetworkingV1Ingress added in v1.9.9

func GetNetworkingV1Ingress(namespace, name string, lister informers.SharedInformerFactory) (*v1.Ingress, error)

func GetPVCYaml added in v1.9.9

func GetPVCYaml(ns string, name string, cl client.Client) ([]byte, bool, error)

func GetPVCYamlFormat added in v1.9.9

func GetPVCYamlFormat(ns string, name string, cl client.Client) ([]byte, bool, error)

func GetPod

func GetPod(ns, name string, cl client.Client) (*corev1.Pod, bool, error)

func GetPvc added in v1.9.9

func GetPvc(ns, name string, cl client.Client) (*corev1.PersistentVolumeClaim, bool, error)

func GetResourceInCache

func GetResourceInCache(ns, name string, obj client.Object, cl client.Reader) (bool, error)

GetResourceInCache gets a specific Kubernetes object in local cache, object can be any types which are registered by "scheme.AddToScheme()". Return true if object is found, false if not, or an error if something bad happened.

func GetResourceJSONInCache

func GetResourceJSONInCache(ns, name string, gvk schema.GroupVersionKind, cl client.Reader) ([]byte, bool, error)

GetResourceJSONInCache gets a specific Kubernetes object in local cache, and return a representation in json format. Return true if object is found, false if not, or an error if something bad happened.

func GetResourceJSONInCacheFormat added in v1.9.9

func GetResourceJSONInCacheFormat(ns, name string, gvk schema.GroupVersionKind, cl client.Reader) ([]byte, bool, error)

func GetResourceYamlInCache

func GetResourceYamlInCache(ns, name string, gvk schema.GroupVersionKind, cl client.Reader) ([]byte, bool, error)

GetResourceYamlInCache gets a specific Kubernetes object in local cache, and return a representation in yaml format. Return true if object is found, false if not, or an error if something bad happened.

func GetResourceYamlInCacheFormat added in v1.9.9

func GetResourceYamlInCacheFormat(ns, name string, gvk schema.GroupVersionKind, cl client.Reader) ([]byte, bool, error)

func GetSecret

func GetSecret(ns, name string, cl client.Client) (*corev1.Secret, bool, error)

func GetSecretYaml added in v1.9.9

func GetSecretYaml(ns string, name string, cl client.Client) ([]byte, bool, error)

func GetSecretYamlFormat added in v1.9.9

func GetSecretYamlFormat(ns string, name string, cl client.Client) ([]byte, bool, error)

func GetService

func GetService(ns, name string, cl client.Client) (*corev1.Service, bool, error)

func GetServiceYaml added in v1.9.9

func GetServiceYaml(ns string, name string, cl client.Client) ([]byte, bool, error)

func GetServiceYamlFormat added in v1.9.9

func GetServiceYamlFormat(ns string, name string, cl client.Client) ([]byte, bool, error)

func GetStatefulSet

func GetStatefulSet(ns, name string, cl client.Client) (*appsv1.StatefulSet, bool, error)

func GetStatefulSetYaml added in v1.5.0

func GetStatefulSetYaml(ns string, name string, cl client.Client) ([]byte, bool, error)

func GetStatefulSetYamlFormat added in v1.9.9

func GetStatefulSetYamlFormat(ns string, name string, cl client.Client) ([]byte, bool, error)

func GetUnstructuredIngress added in v1.9.9

func GetUnstructuredIngress(namespace, name string, cl client.Client, clientset *kubernetes.Clientset) (*unstructured.Unstructured, bool, error)

func ListConfigMaps

func ListConfigMaps(ns string, selector labels.Selector, cl client.Client) ([]*corev1.ConfigMap, error)

func ListConfigMapsYaml

func ListConfigMapsYaml(ns string, selector labels.Selector, cl client.Client) ([][]byte, error)

func ListDeployments

func ListDeployments(ns string, selector labels.Selector, cl client.Client) ([]*appsv1.Deployment, error)

func ListDeploymentsWithCache added in v1.9.9

func ListDeploymentsWithCache(selector labels.Selector, lister informers.SharedInformerFactory) ([]*appsv1.Deployment, error)

func ListDeploymentsYaml

func ListDeploymentsYaml(ns string, selector labels.Selector, cl client.Client) ([][]byte, error)

func ListEvents

func ListEvents(ns string, selector fields.Selector, cl client.Reader) ([]*corev1.Event, error)

func ListExtensionsV1Beta1Ingresses added in v1.9.9

func ListExtensionsV1Beta1Ingresses(selector labels.Selector, lister informers.SharedInformerFactory) ([]*extensionsv1beta1.Ingress, error)

ListExtensionsV1Beta1Ingresses gets the ingress (extensions/v1beta1) from the informer

func ListIngresses

func ListIngresses(namespace string, cl client.Client, lessThan122 bool) (*unstructured.UnstructuredList, error)

func ListIngressesFormat added in v1.12.0

func ListIngressesFormat(namespace string, cl client.Client, lessThan122 bool) ([]*extensions.Ingress, error)

func ListIngressesYaml

func ListIngressesYaml(ns string, selector labels.Selector, cl client.Client) ([][]byte, error)

func ListJobs

func ListJobs(ns string, selector labels.Selector, cl client.Client) ([]*batchv1.Job, error)

func ListNamespaces

func ListNamespaces(cl client.Reader) ([]*corev1.Namespace, error)

func ListNetworkingV1Ingress added in v1.9.9

func ListNetworkingV1Ingress(selector labels.Selector, lister informers.SharedInformerFactory) ([]*v1.Ingress, error)

func ListNodes

func ListNodes(cl client.Client) ([]*corev1.Node, error)

func ListPods

func ListPods(ns string, selector labels.Selector, cl client.Client) ([]*corev1.Pod, error)

func ListPodsWithCache added in v1.9.9

func ListPodsWithCache(selector labels.Selector, informer informers.SharedInformerFactory) ([]*corev1.Pod, error)

func ListPvcs added in v1.9.9

func ListPvcs(ns string, selector fields.Selector, cl client.Reader) ([]*corev1.PersistentVolumeClaim, error)

func ListResourceInCache

func ListResourceInCache(ns string, selector labels.Selector, fieldSelector fields.Selector, obj client.ObjectList, cl client.Reader) error

ListResourceInCache gets a set of specific Kubernetes object in local cache, object can be any types which are registered by "scheme.AddToScheme()". Important: fieldSelector must be nil or contain just one kv pair, otherwise, controller-runtime will return error.

func ListResourceJSONInCache

func ListResourceJSONInCache(ns string, selector labels.Selector, fieldSelector fields.Selector, gvk schema.GroupVersionKind, cl client.Reader) ([][]byte, error)

ListResourceJSONInCache gets a set of specific Kubernetes object in local cache, and return a representation in json format.

func ListResourceYamlInCache

func ListResourceYamlInCache(ns string, selector labels.Selector, fieldSelector fields.Selector, gvk schema.GroupVersionKind, cl client.Reader) ([][]byte, error)

ListResourceYamlInCache gets a set of specific Kubernetes object in local cache, and return a representation in yaml format.

func ListSecrets added in v1.9.9

func ListSecrets(ns string, cl client.Client) ([]*corev1.Secret, error)

func ListServices

func ListServices(ns string, selector labels.Selector, cl client.Client) ([]*corev1.Service, error)

func ListServicesWithCache added in v1.9.9

func ListServicesWithCache(selector labels.Selector, lister informers.SharedInformerFactory) ([]*corev1.Service, error)

func ListServicesYaml

func ListServicesYaml(ns string, selector labels.Selector, cl client.Client) ([][]byte, error)

func ListStatefulSets

func ListStatefulSets(ns string, selector labels.Selector, cl client.Client) ([]*appsv1.StatefulSet, error)

func ListStatefulSetsWithCache added in v1.9.9

func ListStatefulSetsWithCache(selector labels.Selector, lister informers.SharedInformerFactory) ([]*appsv1.StatefulSet, error)

func ListStatefulSetsYaml

func ListStatefulSetsYaml(ns string, selector labels.Selector, cl client.Client) ([][]byte, error)

func ListUnstructuredResourceInCache

func ListUnstructuredResourceInCache(ns string, selector labels.Selector, fieldSelector fields.Selector, gvk schema.GroupVersionKind, cl client.Reader) ([]*unstructured.Unstructured, error)

ListUnstructuredResourceInCache gets a set of specific Kubernetes object in local cache, and return a representation in yaml format.

Types

This section is empty.

Jump to

Keyboard shortcuts

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