secrets

package
v1.4.1 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2024 License: Apache-2.0 Imports: 34 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EnsureCertificate

func EnsureCertificate[
	T interface {
		*operatorv1beta1.ControlPlane | *operatorv1beta1.DataPlane
		client.Object
	},
](
	ctx context.Context,
	owner T,
	subject string,
	mtlsCASecretNN types.NamespacedName,
	usages []certificatesv1.KeyUsage,
	cl client.Client,
	additionalMatchingLabels client.MatchingLabels,
) (op.Result, *corev1.Secret, error)

EnsureCertificate creates a namespace/name Secret for subject signed by the CA in the mtlsCASecretNamespace/mtlsCASecretName Secret, or does nothing if a namespace/name Secret is already present. It returns a boolean indicating if it created a Secret and an error indicating any failures it encountered.

func GetManagedLabelForServiceSecret

func GetManagedLabelForServiceSecret(svcNN types.NamespacedName) client.MatchingLabels

GetManagedLabelForServiceSecret returns a label selector for the ServiceSecret.

func IsTLSSecretValid added in v1.3.0

func IsTLSSecretValid(secret *corev1.Secret) bool

IsTLSSecretValid checks if a Secret contains a valid TLS certificate and key.

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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