hook

package
v1.2.6 Latest Latest
Warning

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

Go to latest
Published: Aug 5, 2025 License: Apache-2.0 Imports: 6 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package hook contains structures and interfaces for implementing admission webhooks handlers.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AllowAlways added in v1.2.6

AllowAlways is a trivial AdmitFunc that always allows the admission request. This is useful for implementing fail-open webhook behavior.

Types

type AdmitFunc

AdmitFunc defines how to process an admission request

type Handler

type Handler struct {
	Accessor      config.ConfigAccessor
	ObjectCreator types.ObjectCreator
	ObjectType    metav1.Object
	Create        AdmitFunc
	Delete        AdmitFunc
	Update        AdmitFunc
	Connect       AdmitFunc
	Store         types.ResourceStore
}

Handler represents the set of functions for each operation in an admission webhook.

func (*Handler) Execute

Execute evaluates the request and try to execute the function for operation specified in the request.

Jump to

Keyboard shortcuts

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