resolver

package
v2.9.1 Latest Latest
Warning

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

Go to latest
Published: Dec 16, 2022 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ResolveAuthRefAndPodIdentity added in v2.4.0

func ResolveAuthRefAndPodIdentity(ctx context.Context, client client.Client, logger logr.Logger,
	triggerAuthRef *kedav1alpha1.ScaledObjectAuthRef, podTemplateSpec *corev1.PodTemplateSpec,
	namespace string, secretsLister corev1listers.SecretLister) (map[string]string, kedav1alpha1.AuthPodIdentity, error)

ResolveAuthRefAndPodIdentity provides authentication parameters and pod identity needed authenticate scaler with the environment.

func ResolveContainerEnv

func ResolveContainerEnv(ctx context.Context, client client.Client, logger logr.Logger, podSpec *corev1.PodSpec, containerName, namespace string, secretsLister corev1listers.SecretLister) (map[string]string, error)

ResolveContainerEnv resolves all environment variables in a container. It returns either map of env variable key and value or error if there is any.

func ResolveScaleTargetPodSpec added in v2.4.0

func ResolveScaleTargetPodSpec(ctx context.Context, kubeClient client.Client, logger logr.Logger, scalableObject interface{}) (*corev1.PodTemplateSpec, string, error)

ResolveScaleTargetPodSpec for given scalableObject inspects the scale target workload, which could be almost any k8s resource (Deployment, StatefulSet, CustomResource...) and for the given resource returns *corev1.PodTemplateSpec and a name of the container which is being used for referencing environment variables

Types

type AzureKeyVaultHandler added in v2.7.0

type AzureKeyVaultHandler struct {
	// contains filtered or unexported fields
}

func NewAzureKeyVaultHandler added in v2.7.0

func NewAzureKeyVaultHandler(v *kedav1alpha1.AzureKeyVault) *AzureKeyVaultHandler

func (*AzureKeyVaultHandler) Initialize added in v2.7.0

func (vh *AzureKeyVaultHandler) Initialize(ctx context.Context, client client.Client, logger logr.Logger, triggerNamespace string, secretsLister corev1listers.SecretLister) error

func (*AzureKeyVaultHandler) Read added in v2.7.0

func (vh *AzureKeyVaultHandler) Read(ctx context.Context, secretName string, version string) (string, error)

type HashicorpVaultHandler

type HashicorpVaultHandler struct {
	// contains filtered or unexported fields
}

HashicorpVaultHandler is specification of Hashi Corp Vault

func NewHashicorpVaultHandler

func NewHashicorpVaultHandler(v *kedav1alpha1.HashiCorpVault) *HashicorpVaultHandler

NewHashicorpVaultHandler creates a HashicorpVaultHandler object

func (*HashicorpVaultHandler) Initialize

func (vh *HashicorpVaultHandler) Initialize(logger logr.Logger) error

Initialize the Vault client

func (*HashicorpVaultHandler) Read

func (vh *HashicorpVaultHandler) Read(path string) (*vaultapi.Secret, error)

func (*HashicorpVaultHandler) Stop

func (vh *HashicorpVaultHandler) Stop()

Stop is responsible for stoping the renew token process

Jump to

Keyboard shortcuts

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