mutating

package
v0.0.0-...-7f68784 Latest Latest
Warning

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

Go to latest
Published: Aug 6, 2020 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// SidecarSetHashAnnotation represents the key of a sidecarset hash
	SidecarSetHashAnnotation = "kruise.io/sidecarset-hash"
	// SidecarSetHashWithoutImageAnnotation represents the key of a sidecarset hash without images of sidecar
	SidecarSetHashWithoutImageAnnotation = "kruise.io/sidecarset-hash-without-image"
)

Variables

View Source
var (
	// HandlerMap contains admission webhook handlers
	HandlerMap = map[string]admission.Handler{
		"mutate-apps-kruise-io-v1alpha1-sidecarset": &SidecarSetCreateHandler{},
	}
)

Functions

func SidecarSetHash

func SidecarSetHash(sidecarSet *appsv1alpha1.SidecarSet) (string, error)

SidecarSetHash returns a hash of the SidecarSet. The Containers are taken into account.

func SidecarSetHashWithoutImage

func SidecarSetHashWithoutImage(sidecarSet *appsv1alpha1.SidecarSet) (string, error)

SidecarSetHashWithoutImage calculates hash without sidecars's image

Types

type SidecarSetCreateHandler

type SidecarSetCreateHandler struct {

	// Decoder decodes objects
	Decoder *admission.Decoder
}

SidecarSetCreateHandler handles SidecarSet

func (*SidecarSetCreateHandler) Handle

Handle handles admission requests.

func (*SidecarSetCreateHandler) InjectDecoder

func (h *SidecarSetCreateHandler) InjectDecoder(d *admission.Decoder) error

InjectDecoder injects the decoder into the SidecarSetCreateHandler

Jump to

Keyboard shortcuts

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