v1

package
v0.0.0-...-8cdc715 Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2022 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package v1 contains API Schema definitions for the admissionregistration v1 API group +kubebuilder:object:generate=true +groupName=admissionregistration.zoetrope.github.io

Index

Constants

View Source
const (
	NamespacedMutatingWebhookConfigurationApplied = NamespacedMutatingWebhookConfigurationStatus("Applied")
)
View Source
const (
	NamespacedValidatingWebhookConfigurationApplied = NamespacedValidatingWebhookConfigurationStatus("Applied")
)

Variables

View Source
var (
	// GroupVersion is group version used to register these objects
	GroupVersion = schema.GroupVersion{Group: "admissionregistration.zoetrope.github.io", Version: "v1"}

	// SchemeBuilder is used to add go types to the GroupVersionKind scheme
	SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion}

	// AddToScheme adds the types in this group-version to the given scheme.
	AddToScheme = SchemeBuilder.AddToScheme
)

Functions

This section is empty.

Types

type MutatingWebhook

type MutatingWebhook struct {
	// Name is the name of the admission webhook.
	//+kubebuilder:validation:Required
	Name string `json:"name"`

	// ClientConfig defines how to communicate with the hook.
	//+kubebuilder:validation:Required
	ClientConfig admissionv1apply.WebhookClientConfigApplyConfiguration `json:"clientConfig"`

	// Rules describes what operations on what resources/subresources the webhook cares about.
	Rules []*admissionv1apply.RuleWithOperationsApplyConfiguration `json:"rules,omitempty"`

	// FailurePolicy defines how unrecognized errors from the admission endpoint are handled -
	// allowed values are Ignore or Fail. Defaults to Fail.
	// +kubebuilder:default="Fail"
	// +optional
	FailurePolicy *admissionv1.FailurePolicyType `json:"failurePolicy,omitempty"`

	// MatchPolicy defines how the "rules" list is used to match incoming requests.
	// Allowed values are "Exact" or "Equivalent".
	// +kubebuilder:default="Equivalent"
	// +optional
	MatchPolicy *admissionv1.MatchPolicyType `json:"matchPolicy,omitempty"`

	// ObjectSelector decides whether to run the webhook based on if the
	// object has matching labels.
	// +optional
	ObjectSelector *metav1apply.LabelSelectorApplyConfiguration `json:"objectSelector,omitempty"`

	// SideEffects states whether this webhook has side effects.
	SideEffects *admissionv1.SideEffectClass `json:"sideEffects"`

	// TimeoutSeconds specifies the timeout for this webhook. After the timeout passes,
	// +kubebuilder:default=10
	// +optional
	TimeoutSeconds *int32 `json:"timeoutSeconds,omitempty"`

	// AdmissionReviewVersions is an ordered list of preferred `AdmissionReview`
	// versions the Webhook expects.
	AdmissionReviewVersions []string `json:"admissionReviewVersions"`

	// ReinvocationPolicy indicates whether this webhook should be called multiple times as part of a single admission evaluation.
	// +kubebuilder:default="Never"
	// +optional
	ReinvocationPolicy *admissionv1.ReinvocationPolicyType `json:"reinvocationPolicy,omitempty"`
}

MutatingWebhook describes an admission webhook and the resources and operations it applies to.

func (*MutatingWebhook) DeepCopy

func (in *MutatingWebhook) DeepCopy() *MutatingWebhook

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MutatingWebhook.

func (*MutatingWebhook) DeepCopyInto

func (in *MutatingWebhook) DeepCopyInto(out *MutatingWebhook)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type NamespacedMutatingWebhookConfiguration

type NamespacedMutatingWebhookConfiguration struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	// Webhooks is a list of webhooks and the affected resources and operations.
	// +optional
	// +patchMergeKey=name
	// +patchStrategy=merge
	Webhooks []MutatingWebhook `json:"webhooks,omitempty" patchStrategy:"merge" patchMergeKey:"name"`

	// ServiceAccountName is the name of the ServiceAccount to use to check access to resources that this webhook will validate
	// +kubebuilder:default="default"
	ServiceAccountName string `json:"serviceAccountName"`

	Status NamespacedMutatingWebhookConfigurationStatus `json:"status,omitempty"`
}

NamespacedMutatingWebhookConfiguration is the Schema for the NamespacedMutatingWebhookConfigurations API

func (NamespacedMutatingWebhookConfiguration) ConfigName

func (*NamespacedMutatingWebhookConfiguration) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NamespacedMutatingWebhookConfiguration.

func (*NamespacedMutatingWebhookConfiguration) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*NamespacedMutatingWebhookConfiguration) DeepCopyObject

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type NamespacedMutatingWebhookConfigurationList

type NamespacedMutatingWebhookConfigurationList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []NamespacedMutatingWebhookConfiguration `json:"items"`
}

NamespacedMutatingWebhookConfigurationList contains a list of NamespacedMutatingWebhookConfiguration

func (*NamespacedMutatingWebhookConfigurationList) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NamespacedMutatingWebhookConfigurationList.

func (*NamespacedMutatingWebhookConfigurationList) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*NamespacedMutatingWebhookConfigurationList) DeepCopyObject

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type NamespacedMutatingWebhookConfigurationStatus

type NamespacedMutatingWebhookConfigurationStatus string

NamespacedMutatingWebhookConfigurationStatus defines the observed state of NamespacedMutatingWebhookConfiguration +kubebuilder:validation:Enum=Applied

type NamespacedValidatingWebhookConfiguration

type NamespacedValidatingWebhookConfiguration struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	// Webhooks is a list of webhooks and the affected resources and operations.
	// +optional
	// +patchMergeKey=name
	// +patchStrategy=merge
	Webhooks []ValidatingWebhook `json:"webhooks,omitempty" patchStrategy:"merge" patchMergeKey:"name"`

	// ServiceAccountName is the name of the ServiceAccount to use to check access to resources that this webhook will validate
	// +kubebuilder:default="default"
	ServiceAccountName string `json:"serviceAccountName"`

	Status NamespacedValidatingWebhookConfigurationStatus `json:"status,omitempty"`
}

NamespacedValidatingWebhookConfiguration is the Schema for the namespacedvalidatingwebhookconfigurations API

func (NamespacedValidatingWebhookConfiguration) ConfigName

func (*NamespacedValidatingWebhookConfiguration) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NamespacedValidatingWebhookConfiguration.

func (*NamespacedValidatingWebhookConfiguration) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*NamespacedValidatingWebhookConfiguration) DeepCopyObject

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type NamespacedValidatingWebhookConfigurationList

type NamespacedValidatingWebhookConfigurationList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []NamespacedValidatingWebhookConfiguration `json:"items"`
}

NamespacedValidatingWebhookConfigurationList contains a list of NamespacedValidatingWebhookConfiguration

func (*NamespacedValidatingWebhookConfigurationList) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NamespacedValidatingWebhookConfigurationList.

func (*NamespacedValidatingWebhookConfigurationList) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*NamespacedValidatingWebhookConfigurationList) DeepCopyObject

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type NamespacedValidatingWebhookConfigurationStatus

type NamespacedValidatingWebhookConfigurationStatus string

NamespacedValidatingWebhookConfigurationStatus defines the observed state of NamespacedValidatingWebhookConfiguration +kubebuilder:validation:Enum=Applied

type ValidatingWebhook

type ValidatingWebhook struct {
	// Name is the name of the admission webhook.
	//+kubebuilder:validation:Required
	Name string `json:"name" protobuf:"bytes,1,opt,name=name"`

	// ClientConfig defines how to communicate with the hook.
	//+kubebuilder:validation:Required
	ClientConfig admissionv1apply.WebhookClientConfigApplyConfiguration `json:"clientConfig"`

	// Rules describes what operations on what resources/subresources the webhook cares about.
	Rules []*admissionv1apply.RuleWithOperationsApplyConfiguration `json:"rules,omitempty"`

	// FailurePolicy defines how unrecognized errors from the admission endpoint are handled -
	// allowed values are Ignore or Fail. Defaults to Fail.
	// +kubebuilder:default="Fail"
	// +optional
	FailurePolicy *admissionv1.FailurePolicyType `json:"failurePolicy,omitempty"`

	// matchPolicy defines how the "rules" list is used to match incoming requests.
	// Allowed values are "Exact" or "Equivalent".
	// +kubebuilder:default="Equivalent"
	// +optional
	MatchPolicy *admissionv1.MatchPolicyType `json:"matchPolicy,omitempty"`

	// ObjectSelector decides whether to run the webhook based on if the
	// object has matching labels.
	// +optional
	ObjectSelector *metav1apply.LabelSelectorApplyConfiguration `json:"objectSelector,omitempty"`

	// SideEffects states whether this webhook has side effects.
	SideEffects *admissionv1.SideEffectClass `json:"sideEffects"`

	// TimeoutSeconds specifies the timeout for this webhook. After the timeout passes,
	// +kubebuilder:default=10
	// +optional
	TimeoutSeconds *int32 `json:"timeoutSeconds,omitempty"`

	// AdmissionReviewVersions is an ordered list of preferred `AdmissionReview`
	// versions the Webhook expects.
	AdmissionReviewVersions []string `json:"admissionReviewVersions"`
}

ValidatingWebhook describes an admission webhook and the resources and operations it applies to.

func (*ValidatingWebhook) DeepCopy

func (in *ValidatingWebhook) DeepCopy() *ValidatingWebhook

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ValidatingWebhook.

func (*ValidatingWebhook) DeepCopyInto

func (in *ValidatingWebhook) DeepCopyInto(out *ValidatingWebhook)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

Jump to

Keyboard shortcuts

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