kube

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Mar 17, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrSecretNotFound = fmt.Errorf("service account's secret not found")

Functions

func BuildClient

func BuildClient(kfg []byte) (*kubernetes.Clientset, error)

func CreateServiceAccount

func CreateServiceAccount(ctx context.Context, cli kubernetes.Clientset, name string, namespace string) (*corev1.ServiceAccount, error)

func CreateServiceAccountSecret

func CreateServiceAccountSecret(ctx context.Context, cli kubernetes.Clientset, name string, namespace string, sa *corev1.ServiceAccount) (*corev1.Secret, error)

func DeleteServiceAccountSecret

func DeleteServiceAccountSecret(ctx context.Context, cli kubernetes.Clientset, name string, namespace string) error

func GetConfigDefaultNamespace

func GetConfigDefaultNamespace() (*string, error)

func GetCurrentContextClient

func GetCurrentContextClient() (*kubernetes.Clientset, error)

func GetLastServiceAccountSecrets

func GetLastServiceAccountSecrets(ctx context.Context, cli kubernetes.Clientset, name string, namespace string) (*corev1.Secret, error)

func GetRESTConfig

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

func GetServiceAccountSecrets

func GetServiceAccountSecrets(ctx context.Context, cli kubernetes.Clientset, name string, namespace string) ([]corev1.Secret, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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