kuberneteshelper

package
v1.2.2 Latest Latest
Warning

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

Go to latest
Published: Apr 17, 2024 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateOrUpdateServiceAccount

func CreateOrUpdateServiceAccount(ctx context.Context, kubeClient client.Client, namespace, name, clientID, tenantID string, tokenExpiration time.Duration) error

Create ServiceAccount in the cluster If the ServiceAccount already exists, error is returned

func DeleteServiceAccount

func DeleteServiceAccount(ctx context.Context, kubeClient client.Client, namespace, name string) error

Delete ServiceAccount in the cluster

func GetKubeClient

func GetKubeClient() (client.Client, error)

GetKubeClient returns a Kubernetes clientset.

func GetKubeConfig

func GetKubeConfig() (*rest.Config, error)

GetKubeConfig returns the kubeconfig

func GetObject added in v0.10.0

func GetObject(ctx context.Context, kubeClient client.Client, namespace string, name string, obj client.Object) (client.Object, error)

GetObject returns an object from the Kubernetes cluster.

func GetServiceAccount added in v0.10.0

func GetServiceAccount(ctx context.Context, kubeClient client.Client, namespace, name string) (*corev1.ServiceAccount, error)

Get ServiceAccount in the cluster

func ListAzureIdentity added in v0.10.0

func ListAzureIdentity(ctx context.Context, kubeClient client.Client, namespace string) ([]aadpodv1.AzureIdentity, error)

ListAzureIdentity returns a list of AzureIdentity

func ListAzureIdentityBinding added in v0.10.0

func ListAzureIdentityBinding(ctx context.Context, kubeClient client.Client, namespace string) ([]aadpodv1.AzureIdentityBinding, error)

ListAzureIdentityBinding returns a list of AzureIdentityBinding

func ListPods added in v0.10.0

func ListPods(ctx context.Context, kubeClient client.Client, namespace string, labels map[string]string) (map[string]corev1.Pod, error)

ListPods returns a list of Pods in the given namespace that match the given label selector

Types

This section is empty.

Jump to

Keyboard shortcuts

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