admission

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jun 9, 2020 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Deserializer  = codecs.UniversalDeserializer()
	InternalError = errors.New("internal admission controller error")
)

Functions

func Handler

func Handler(admitter Admitter) http.HandlerFunc

Types

type Admitter

type Admitter interface {
	Admit(review *v1beta1.AdmissionRequest) ([]PatchOperation, error)
}

type PatchOperation

type PatchOperation struct {
	Operation string      `json:"op"`
	Path      string      `json:"path"`
	Value     interface{} `json:"value"`
}

func PatchAdd

func PatchAdd(path string, value interface{}) PatchOperation

func PatchReplace

func PatchReplace(path string, value interface{}) PatchOperation

Jump to

Keyboard shortcuts

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