Documentation ¶
Overview ¶
Package v1alpha1 contains Policy resources. +kubebuilder:object:generate=true +groupName=policy.spaces.upbound.io +versionName=v1alpha1
Index ¶
Constants ¶
const ( Group = "policy.spaces.upbound.io" Version = "v1alpha1" )
Package type metadata.
Variables ¶
var ( // SchemeGroupVersion is group version used to register these objects SchemeGroupVersion = schema.GroupVersion{Group: Group, Version: Version} // SchemeBuilder is used to add go types to the GroupVersionKind scheme SchemeBuilder = &scheme.Builder{GroupVersion: SchemeGroupVersion} // AddToScheme adds the types in this group-version to the given scheme. AddToScheme = SchemeBuilder.AddToScheme )
var ( reflect.TypeOf(SharedUpboundPolicy{}).Name() SharedUpboundPolicyGroupKind = schema.GroupKind{Group: Group, Kind: SharedUpboundPolicyKind}.String() SharedUpboundPolicyKindAPIVersion = SharedUpboundPolicyKind + "." + SchemeGroupVersion.String() SharedUpboundPolicyGroupVersionKind = SchemeGroupVersion.WithKind(SharedUpboundPolicyKind) SharedUpboundPolicyGroupVersionResource = SchemeGroupVersion.WithResource("sharedupboundpolicies") )SharedUpboundPolicyKind =
Functions ¶
This section is empty.
Types ¶
type ClusterPolicyConditionType ¶
type ClusterPolicyConditionType string
ClusterPolicyConditionType is controlplane ClusterPolicy condition type
type ClusterPolicyStatusCondition ¶
type ClusterPolicyStatusCondition struct { Type ClusterPolicyConditionType `json:"type"` Status corev1.ConditionStatus `json:"status"` // +optional Message string `json:"message,omitempty"` }
ClusterPolicyStatusCondition is controlplane ClusterPolicy status condition
func (*ClusterPolicyStatusCondition) DeepCopy ¶
func (in *ClusterPolicyStatusCondition) DeepCopy() *ClusterPolicyStatusCondition
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterPolicyStatusCondition.
func (*ClusterPolicyStatusCondition) DeepCopyInto ¶
func (in *ClusterPolicyStatusCondition) DeepCopyInto(out *ClusterPolicyStatusCondition)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SharedUpboundPolicy ¶
type SharedUpboundPolicy struct {}
SharedUpboundPolicy specifies a shared Kyverno policy projected into the specified ControlPlanes of the same namespace as SharedUpboundPolicy. +kubebuilder:object:root=true +kubebuilder:storageversion +kubebuilder:printcolumn:name="Provisioned",type=string,JSONPath=`.metadata.annotations.sharedupboundpolicies\.internal\.spaces\.upbound\.io/provisioned-total` +kubebuilder:printcolumn:name="AGE",type="date",JSONPath=".metadata.creationTimestamp" +kubebuilder:subresource:status +kubebuilder:resource:scope=Namespaced,categories={policies},shortName=sup
func (*SharedUpboundPolicy) ControlPlaneSelector ¶
func (c *SharedUpboundPolicy) ControlPlaneSelector() func(obj client.Object) (bool, error)
ControlPlaneSelector returns a function that can be used for checking if a given object matches the selector.
func (*SharedUpboundPolicy) DeepCopy ¶
func (in *SharedUpboundPolicy) DeepCopy() *SharedUpboundPolicy
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SharedUpboundPolicy.
func (*SharedUpboundPolicy) DeepCopyInto ¶
func (in *SharedUpboundPolicy) DeepCopyInto(out *SharedUpboundPolicy)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*SharedUpboundPolicy) DeepCopyObject ¶
func (in *SharedUpboundPolicy) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type SharedUpboundPolicyList ¶
type SharedUpboundPolicyList struct {}
SharedUpboundPolicyList contains a list of SharedUpboundPolicy. +kubebuilder:object:root=true
func (*SharedUpboundPolicyList) DeepCopy ¶
func (in *SharedUpboundPolicyList) DeepCopy() *SharedUpboundPolicyList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SharedUpboundPolicyList.
func (*SharedUpboundPolicyList) DeepCopyInto ¶
func (in *SharedUpboundPolicyList) DeepCopyInto(out *SharedUpboundPolicyList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*SharedUpboundPolicyList) DeepCopyObject ¶
func (in *SharedUpboundPolicyList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*SharedUpboundPolicyList) Objects ¶
func (s *SharedUpboundPolicyList) Objects() []client.Object
Objects return the list of items.
type SharedUpboundPolicyProvisioningFailure ¶
type SharedUpboundPolicyProvisioningFailure struct { string `json:"controlPlane"` // +optional Conditions []metav1.Condition `json:"conditions,omitempty"` }ControlPlane
SharedUpboundPolicyProvisioningFailure defines policy provisioning failure.
func (*SharedUpboundPolicyProvisioningFailure) DeepCopy ¶
func (in *SharedUpboundPolicyProvisioningFailure) DeepCopy() *SharedUpboundPolicyProvisioningFailure
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SharedUpboundPolicyProvisioningFailure.
func (*SharedUpboundPolicyProvisioningFailure) DeepCopyInto ¶
func (in *SharedUpboundPolicyProvisioningFailure) DeepCopyInto(out *SharedUpboundPolicyProvisioningFailure)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SharedUpboundPolicyProvisioningSuccess ¶
type SharedUpboundPolicyProvisioningSuccess struct { string `json:"controlPlane"` }ControlPlane
SharedUpboundPolicyProvisioningSuccess defines policy provisioning success.
func (*SharedUpboundPolicyProvisioningSuccess) DeepCopy ¶
func (in *SharedUpboundPolicyProvisioningSuccess) DeepCopy() *SharedUpboundPolicyProvisioningSuccess
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SharedUpboundPolicyProvisioningSuccess.
func (*SharedUpboundPolicyProvisioningSuccess) DeepCopyInto ¶
func (in *SharedUpboundPolicyProvisioningSuccess) DeepCopyInto(out *SharedUpboundPolicyProvisioningSuccess)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SharedUpboundPolicySpec ¶
type SharedUpboundPolicySpec struct { // optional, if not set, SharedUpboundPolicy name will be used. // When set, it is immutable. // +kubebuilder:validation:XValidation:rule="self == oldSelf",message="policyName is immutable" // +kubebuilder:validation:MaxLength=253 // +kubebuilder:validation:MinLength=1 // +optional PolicyName string `json:"policyName,omitempty"` // +optional PolicyMetadata *v1alpha1.ResourceMetadata `json:"policyMetadata,omitempty"` // matching the provided selector. Either names or a labelSelector must be specified. // +kubebuilder:validation:XValidation:rule="(has(self.labelSelectors) || has(self.names)) && (size(self.labelSelectors) > 0 || size(self.names) > 0)",message="either names or a labelSelector must be specified" ControlPlaneSelector v1alpha1.ResourceSelector `json:"controlPlaneSelector"` // See https://htmlpreview.github.io/?https://github.com/kyverno/kyverno/blob/main/docs/user/crd/index.html#kyverno.io/v1.Spec kyvernov1.Spec `json:",inline"` }
SharedUpboundPolicySpec defines the desired state of SharedUpboundPolicy. +kubebuilder:validation:XValidation:rule="has(self.policyName) == has(oldSelf.policyName)",message="policyName is immutable"
func (*SharedUpboundPolicySpec) DeepCopy ¶
func (in *SharedUpboundPolicySpec) DeepCopy() *SharedUpboundPolicySpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SharedUpboundPolicySpec.
func (*SharedUpboundPolicySpec) DeepCopyInto ¶
func (in *SharedUpboundPolicySpec) DeepCopyInto(out *SharedUpboundPolicySpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SharedUpboundPolicyStatus ¶
type SharedUpboundPolicyStatus struct { // +optional ObservedGeneration *int64 `json:"observedGeneration,omitempty"` // +optional // +listType=map // +listMapKey=controlPlane Failed []SharedUpboundPolicyProvisioningFailure `json:"failed,omitempty"` // +optional // +listType=map // +listMapKey=controlPlane Provisioned []SharedUpboundPolicyProvisioningSuccess `json:"provisioned,omitempty"` }
SharedUpboundPolicyStatus defines the observed state of the projected polcies.
func (*SharedUpboundPolicyStatus) DeepCopy ¶
func (in *SharedUpboundPolicyStatus) DeepCopy() *SharedUpboundPolicyStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SharedUpboundPolicyStatus.
func (*SharedUpboundPolicyStatus) DeepCopyInto ¶
func (in *SharedUpboundPolicyStatus) DeepCopyInto(out *SharedUpboundPolicyStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.