Documentation
¶
Overview ¶
Package webhook provides the mutating admission webhook handler for rewriting secret volumes to point to shadow secrets.
Index ¶
Constants ¶
View Source
const ( SecretName = "kloak-webhook-certs" CertKey = "tls.crt" KeyKey = "tls.key" )
View Source
const ( // LabelEnabled is the label used to enable Kloak on a pod or namespace. // Pod-level enablement uses a label (not annotation) so that Kubernetes // objectSelector can match it, allowing the webhook to be scoped precisely. LabelEnabled = "getkloak.io/enabled" // AnnotationEnabled is the annotation injected by the webhook onto mutated pods. // The controller (DaemonSet) reads this to determine if a pod is kloak-enabled. AnnotationEnabled = "getkloak.io/enabled" )
Variables ¶
This section is empty.
Functions ¶
func EnsureWebhookCerts ¶
EnsureWebhookCerts generates a self-signed certificate for the mutating webhook if the secret does not already exist in the cluster.
Types ¶
type Handler ¶
type Handler struct {
// contains filtered or unexported fields
}
func NewHandler ¶
func NewHandler(c client.Client, log *zap.SugaredLogger) *Handler
Click to show internal directories.
Click to hide internal directories.