validation

package
v3.6.22-1+incompatible Latest Latest
Warning

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

Go to latest
Published: Apr 8, 2017 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var RepositoryNameComponentAnchoredRegexp = regexp.MustCompile(`^` + RepositoryNameComponentRegexp.String() + `$`)

RepositoryNameComponentAnchoredRegexp is the version of RepositoryNameComponentRegexp which must completely match the content Copied from github.com/docker/distribution/registry/api/v2/names.go v2.1.1

View Source
var RepositoryNameComponentRegexp = regexp.MustCompile(`[a-z0-9]+(?:[._-][a-z0-9]+)*`)

RepositoryNameComponentRegexp restricts registry path component names to start with at least one letter or number, with following parts able to be separated by one period, dash or underscore. Copied from github.com/docker/distribution/registry/api/v2/names.go v2.1.1

View Source
var RepositoryNameRegexp = regexp.MustCompile(`(?:` + RepositoryNameComponentRegexp.String() + `/)*` + RepositoryNameComponentRegexp.String())

RepositoryNameRegexp builds on RepositoryNameComponentRegexp to allow multiple path components, separated by a forward slash. Copied from github.com/docker/distribution/registry/api/v2/names.go v2.1.1

Functions

func ValidateImage

func ValidateImage(image *api.Image) field.ErrorList

ValidateImage tests required fields for an Image.

func ValidateImageSignature added in v1.3.0

func ValidateImageSignature(signature *api.ImageSignature) field.ErrorList

ValidateImageSignature ensures that given signatures is valid.

func ValidateImageSignatureUpdate added in v1.3.0

func ValidateImageSignatureUpdate(newImageSignature, oldImageSignature *api.ImageSignature) field.ErrorList

ValidateImageSignatureUpdate ensures that the new ImageSignature is valid.

func ValidateImageStream added in v0.4.3

func ValidateImageStream(stream *api.ImageStream) field.ErrorList

ValidateImageStream tests required fields for an ImageStream.

func ValidateImageStreamImport added in v1.1.2

func ValidateImageStreamImport(isi *api.ImageStreamImport) field.ErrorList

func ValidateImageStreamMapping added in v0.4.3

func ValidateImageStreamMapping(mapping *api.ImageStreamMapping) field.ErrorList

ValidateImageStreamMapping tests required fields for an ImageStreamMapping.

func ValidateImageStreamName added in v0.5.3

func ValidateImageStreamName(name string, prefix bool) []string

func ValidateImageStreamStatusUpdate added in v0.4.3

func ValidateImageStreamStatusUpdate(newStream, oldStream *api.ImageStream) field.ErrorList

ValidateImageStreamStatusUpdate tests required fields for an ImageStream status update.

func ValidateImageStreamTag added in v1.0.8

func ValidateImageStreamTag(ist *api.ImageStreamTag) field.ErrorList

ValidateImageStreamTag validates a mutation of an image stream tag, which can happen on PUT

func ValidateImageStreamTagReference added in v1.1.3

func ValidateImageStreamTagReference(tagRef api.TagReference, fldPath *field.Path) field.ErrorList

ValidateImageStreamTagReference ensures that a given tag reference is valid.

func ValidateImageStreamTagUpdate added in v1.0.8

func ValidateImageStreamTagUpdate(newIST, oldIST *api.ImageStreamTag) field.ErrorList

ValidateImageStreamTagUpdate ensures that only the annotations of the IST have changed

func ValidateImageStreamUpdate added in v0.4.3

func ValidateImageStreamUpdate(newStream, oldStream *api.ImageStream) field.ErrorList

func ValidateImageUpdate added in v1.0.7

func ValidateImageUpdate(newImage, oldImage *api.Image) field.ErrorList

func ValidateRegistryAllowedForImport

func ValidateRegistryAllowedForImport(path *field.Path, name, registryHost, registryPort string, allowedRegistries *serverapi.AllowedRegistries) field.ErrorList

Types

This section is empty.

Jump to

Keyboard shortcuts

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