Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DynamicFileClient ¶
type DynamicFileClient interface { // Create iterates a set of YAML documents and calls client.Create on them. Create(ctx context.Context, file []byte) error }
DynamicFileClient interacts with a cluster with file manifests.
type LabelValidationError ¶
type LabelValidationError struct {
// contains filtered or unexported fields
}
LabelValidationError is returned (with a set of underlying violations) when a label is invalid.
func (LabelValidationError) Error ¶
func (e LabelValidationError) Error() string
Error implements the error interface.
func (LabelValidationError) ServiceError ¶
func (LabelValidationError) ServiceError() bool
ServiceError tells the consumer whether this error is caused by invalid input supplied by the client. Client errors are usually returned to the consumer without retrying the operation.
func (LabelValidationError) Validation ¶
func (LabelValidationError) Validation() bool
Validation tells a client that this error is related to a semantic validation of the request. Can be used to translate the error to status codes for example.
func (LabelValidationError) Violations ¶
func (e LabelValidationError) Violations() []string
Violations returns details of the failed validation.
type LabelValidator ¶
type LabelValidator struct {
ForbiddenDomains []string
}
LabelValidator validates Kubernetes object labels.
func (LabelValidator) ValidateKey ¶
func (v LabelValidator) ValidateKey(key string) error
ValidateKey validates a label key.
func (LabelValidator) ValidateLabel ¶
func (v LabelValidator) ValidateLabel(key string, value string) error
ValidateLabel validates both a label key and a value.
func (LabelValidator) ValidateLabels ¶
func (v LabelValidator) ValidateLabels(labels map[string]string) error
ValidateLabels validates a set of label key-value pairs.
func (LabelValidator) ValidateValue ¶
func (v LabelValidator) ValidateValue(value string) error
ValidateValue validates a label value.
type MockDynamicFileClient ¶
MockDynamicFileClient is an autogenerated mock for the DynamicFileClient type.