webhook

package
v0.20.2 Latest Latest
Warning

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

Go to latest
Published: Jan 31, 2025 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SetupWebhookWithManager

func SetupWebhookWithManager(mgr ctrl.Manager, operatorNamespace string, logger logr.Logger) error

SetupWebhookWithManager registers the pod mutation webhook

Types

type PodMutationHandler

type PodMutationHandler struct {
	Client   client.Client
	Decoder  admission.Decoder
	Mutators []PodMutator
	Logger   logr.Logger
}

PodMutationHandler is a webhook handler for mutating Pods

func (*PodMutationHandler) Handle

Handle manages Pod mutations

type PodMutator

type PodMutator interface {
	Mutate(ctx context.Context, ns corev1.Namespace, pod corev1.Pod) (corev1.Pod, error)
}

PodMutator mutates a pod.

Jump to

Keyboard shortcuts

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