Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ValidationIgnorer ¶
type ValidationIgnorer struct {
// contains filtered or unexported fields
}
func NewValidationIgnorer ¶
func NewValidationIgnorer(pairs ...string) *ValidationIgnorer
NewValidationIgnorer initializes the ignorer for the validatior, pairs are in namespace/namePattern format.
func (*ValidationIgnorer) Add ¶
func (iv *ValidationIgnorer) Add(namespace, pattern string)
func (*ValidationIgnorer) ShouldIgnore ¶
func (iv *ValidationIgnorer) ShouldIgnore(namespace, name string) bool
ShouldIgnore checks if a given namespaced name should be ignored based on the patterns.
type Validator ¶
type Validator struct { // If enabled, resources without a validator will be ignored. Otherwise, they will fail. SkipMissing bool // contains filtered or unexported fields }
Validator returns a new validator for custom resources Warning: this is meant for usage in tests only
func NewIstioValidator ¶
func NewValidatorFromCRDs ¶
func NewValidatorFromCRDs(crds ...apiextensions.CustomResourceDefinition) (*Validator, error)
func NewValidatorFromFiles ¶
func (*Validator) ValidateCustomResource ¶
func (*Validator) ValidateCustomResourceYAML ¶
func (v *Validator) ValidateCustomResourceYAML(data string, ignorer *ValidationIgnorer) error
Click to show internal directories.
Click to hide internal directories.