k8s

package
v1.1.6 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2024 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CopyStringMap

func CopyStringMap(source map[string]string) map[string]string

func GetAnnotationsChecksum added in v1.1.2

func GetAnnotationsChecksum(annotations map[string]string) string

GetAnnotationsChecksum takes an annotation map and returns a sha1 checksum.

func GetDeployment added in v0.3.0

func GetDeployment(ctx context.Context, name string, namespace string) (*v1.Deployment, error)

func GetDockhandSecretsListFromK8sSecrets

func GetDockhandSecretsListFromK8sSecrets(ctx context.Context, secretNames []string, namespace string) ([]string, error)

func GetLeaseLock added in v0.3.0

func GetLeaseLock(leaseId string, leaseName string, namespace string) (*resourcelock.LeaseLock, error)

func GetSecretsChecksum

func GetSecretsChecksum(ctx context.Context, names []string, namespace string) (string, error)

GetSecretsChecksum takes a set of secrets in a namespace and returns a checksum of all of the data in those secrets

func GetServiceCertificate

func GetServiceCertificate(ctx context.Context, name string, namespace string) (*tls.Certificate, []byte, error)

GetServiceCertificate for service and namespace.

func UpdateCABundleForWebhook

func UpdateCABundleForWebhook(ctx context.Context, name string, caBundleBytes []byte) error

UpdateCABundleForWebhook updates the CA Bundle

func UpdateDeployment added in v0.3.0

func UpdateDeployment(ctx context.Context, deployment *v1.Deployment, namespace string) (*v1.Deployment, error)

func UpdateTlsCertificateSecret added in v0.3.0

func UpdateTlsCertificateSecret(ctx context.Context, name string, namespace string, serverPem []byte, serverKey []byte, caPem []byte) error

Types

type PatchOperation

type PatchOperation struct {
	Op    string      `json:"op"`
	Path  string      `json:"path"`
	Value interface{} `json:"value,omitempty"`
}

func GenerateMetadataLabelsPatch

func GenerateMetadataLabelsPatch(target map[string]string, added map[string]string) (patch []PatchOperation)

func GenerateSpecTemplateAnnotationPatch

func GenerateSpecTemplateAnnotationPatch(target map[string]string, added map[string]string) (patch []PatchOperation)

Jump to

Keyboard shortcuts

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