Documentation ¶
Overview ¶
Package v1alpha1 is the v1alpha1 version of the API. +k8s:deepcopy-gen=package,register +k8s:openapi-gen=true +groupName=policy.karmada.io
Index ¶
- Constants
- Variables
- func Resource(resource string) schema.GroupResource
- type ClusterAffinity
- type ClusterOverridePolicy
- func (in *ClusterOverridePolicy) DeepCopy() *ClusterOverridePolicy
- func (in *ClusterOverridePolicy) DeepCopyInto(out *ClusterOverridePolicy)
- func (in *ClusterOverridePolicy) DeepCopyObject() runtime.Object
- func (p *ClusterOverridePolicy) GetName() string
- func (p *ClusterOverridePolicy) GetNamespace() string
- func (p *ClusterOverridePolicy) GetOverrideSpec() OverrideSpec
- type ClusterOverridePolicyList
- type ClusterPreferences
- type ClusterPropagationPolicy
- type ClusterPropagationPolicyList
- type ClusterQuotaStatus
- type CommandArgsOverrider
- type DynamicWeightFactor
- type FederatedResourceQuota
- type FederatedResourceQuotaList
- type FederatedResourceQuotaSpec
- type FederatedResourceQuotaStatus
- type FieldSelector
- type ImageComponent
- type ImageOverrider
- type ImagePredicate
- type LabelAnnotationOverrider
- type OverridePolicy
- func (in *OverridePolicy) DeepCopy() *OverridePolicy
- func (in *OverridePolicy) DeepCopyInto(out *OverridePolicy)
- func (in *OverridePolicy) DeepCopyObject() runtime.Object
- func (p *OverridePolicy) GetName() string
- func (p *OverridePolicy) GetNamespace() string
- func (p *OverridePolicy) GetOverrideSpec() OverrideSpec
- type OverridePolicyList
- type OverrideSpec
- type OverriderOperator
- type Overriders
- type Placement
- type PlaintextOverrider
- type PropagationPolicy
- type PropagationPolicyList
- type PropagationSpec
- type ReplicaDivisionPreference
- type ReplicaSchedulingStrategy
- type ReplicaSchedulingType
- type ResourceSelector
- type RuleWithCluster
- type SpreadConstraint
- type SpreadFieldValue
- type StaticClusterAssignment
- type StaticClusterWeight
Constants ¶
const ( // ResourceKindFederatedResourceQuota is kind name of FederatedResourceQuota. ResourceKindFederatedResourceQuota = "FederatedResourceQuota" // ResourceSingularFederatedResourceQuota is singular name of FederatedResourceQuota. ResourceSingularFederatedResourceQuota = "federatedresourcequota" // ResourcePluralFederatedResourceQuota is plural name of FederatedResourceQuota. ResourcePluralFederatedResourceQuota = "federatedresourcequotas" // ResourceNamespaceScopedFederatedResourceQuota indicates if FederatedResourceQuota is NamespaceScoped. ResourceNamespaceScopedFederatedResourceQuota = true )
const ( // ResourceKindOverridePolicy is kind name of OverridePolicy. ResourceKindOverridePolicy = "OverridePolicy" // ResourceSingularOverridePolicy is singular name of OverridePolicy. ResourceSingularOverridePolicy = "overridepolicy" // ResourcePluralOverridePolicy is plural name of OverridePolicy. ResourcePluralOverridePolicy = "overridepolicies" // ResourceNamespaceScopedOverridePolicy indicates if OverridePolicy is NamespaceScoped. ResourceNamespaceScopedOverridePolicy = true // ResourceKindClusterOverridePolicy is kind name of ClusterOverridePolicy. ResourceKindClusterOverridePolicy = "ClusterOverridePolicy" // ResourceSingularClusterOverridePolicy is singular name of ClusterOverridePolicy. ResourceSingularClusterOverridePolicy = "clusteroverridepolicy" // ResourcePluralClusterOverridePolicy is kind plural of ClusterOverridePolicy. ResourcePluralClusterOverridePolicy = "clusteroverridepolicies" // ResourceNamespaceScopedClusterOverridePolicy indicates if ClusterOverridePolicy is NamespaceScoped. ResourceNamespaceScopedClusterOverridePolicy = false )
const ( // ResourceKindPropagationPolicy is kind name of PropagationPolicy. ResourceKindPropagationPolicy = "PropagationPolicy" // ResourceSingularPropagationPolicy is singular name of PropagationPolicy. ResourceSingularPropagationPolicy = "propagationpolicy" // ResourcePluralPropagationPolicy is kind plural name of PropagationPolicy. ResourcePluralPropagationPolicy = "propagationpolicies" // ResourceNamespaceScopedPropagationPolicy indicates if PropagationPolicy is NamespaceScoped. ResourceNamespaceScopedPropagationPolicy = true // ResourceKindClusterPropagationPolicy is kind name of ClusterPropagationPolicy. ResourceKindClusterPropagationPolicy = "ClusterPropagationPolicy" // ResourceSingularClusterPropagationPolicy is singular name of ClusterPropagationPolicy. ResourceSingularClusterPropagationPolicy = "clusterpropagationpolicy" // ResourcePluralClusterPropagationPolicy is plural name of ClusterPropagationPolicy. ResourcePluralClusterPropagationPolicy = "clusterpropagationpolicies" // ResourceNamespaceScopedClusterPropagationPolicy indicates if ClusterPropagationPolicy is NamespaceScoped. ResourceNamespaceScopedClusterPropagationPolicy = false )
const ( // PropagationPolicyNamespaceLabel is added to objects to specify associated PropagationPolicy namespace. PropagationPolicyNamespaceLabel = "propagationpolicy.karmada.io/namespace" // PropagationPolicyNameLabel is added to objects to specify associated PropagationPolicy's name. PropagationPolicyNameLabel = "propagationpolicy.karmada.io/name" // ClusterPropagationPolicyLabel is added to objects to specify associated ClusterPropagationPolicy. ClusterPropagationPolicyLabel = "clusterpropagationpolicy.karmada.io/name" // NamespaceSkipAutoPropagationLabel is added to namespace objects to indicate if // the namespace should be skipped from propagating by the namespace controller. // For example, a namespace with the following label will be skipped: // labels: // namespace.karmada.io/skip-auto-propagation: "true" // // NOTE: If create a ns without this label, then patch it with this label, the ns will not be // synced to new member clusters, but old member clusters still have it. NamespaceSkipAutoPropagationLabel = "namespace.karmada.io/skip-auto-propagation" )
const GroupName = "policy.karmada.io"
GroupName specifies the group name used to register the objects.
Variables ¶
var ( // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. SchemeBuilder runtime.SchemeBuilder // Depreciated: use Install instead AddToScheme = localSchemeBuilder.AddToScheme Install = localSchemeBuilder.AddToScheme )
var GroupVersion = v1.GroupVersion{Group: GroupName, Version: "v1alpha1"}
GroupVersion specifies the group and the version used to register the objects.
var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha1"}
SchemeGroupVersion is group version used to register these objects Deprecated: use GroupVersion instead.
Functions ¶
func Resource ¶
func Resource(resource string) schema.GroupResource
Resource takes an unqualified resource and returns a Group qualified GroupResource
Types ¶
type ClusterAffinity ¶
type ClusterAffinity struct { // LabelSelector is a filter to select member clusters by labels. // If non-nil and non-empty, only the clusters match this filter will be selected. // +optional LabelSelector *metav1.LabelSelector `json:"labelSelector,omitempty"` // FieldSelector is a filter to select member clusters by fields. // If non-nil and non-empty, only the clusters match this filter will be selected. // +optional FieldSelector *FieldSelector `json:"fieldSelector,omitempty"` // ClusterNames is the list of clusters to be selected. // +optional ClusterNames []string `json:"clusterNames,omitempty"` // ExcludedClusters is the list of clusters to be ignored. // +optional ExcludeClusters []string `json:"exclude,omitempty"` }
ClusterAffinity represents the filter to select clusters.
func (*ClusterAffinity) DeepCopy ¶
func (in *ClusterAffinity) DeepCopy() *ClusterAffinity
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterAffinity.
func (*ClusterAffinity) DeepCopyInto ¶
func (in *ClusterAffinity) DeepCopyInto(out *ClusterAffinity)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ClusterOverridePolicy ¶ added in v0.4.0
type ClusterOverridePolicy struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` // Spec represents the desired behavior of ClusterOverridePolicy. Spec OverrideSpec `json:"spec"` }
ClusterOverridePolicy represents the cluster-wide policy that overrides a group of resources to one or more clusters.
func (*ClusterOverridePolicy) DeepCopy ¶ added in v0.4.0
func (in *ClusterOverridePolicy) DeepCopy() *ClusterOverridePolicy
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterOverridePolicy.
func (*ClusterOverridePolicy) DeepCopyInto ¶ added in v0.4.0
func (in *ClusterOverridePolicy) DeepCopyInto(out *ClusterOverridePolicy)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ClusterOverridePolicy) DeepCopyObject ¶ added in v0.4.0
func (in *ClusterOverridePolicy) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*ClusterOverridePolicy) GetName ¶ added in v1.0.0
func (p *ClusterOverridePolicy) GetName() string
GetName returns the name of ClusterOverridePolicy
func (*ClusterOverridePolicy) GetNamespace ¶ added in v1.0.0
func (p *ClusterOverridePolicy) GetNamespace() string
GetNamespace returns the namespace of ClusterOverridePolicy
func (*ClusterOverridePolicy) GetOverrideSpec ¶ added in v1.0.0
func (p *ClusterOverridePolicy) GetOverrideSpec() OverrideSpec
GetOverrideSpec returns the OverrideSpec of ClusterOverridePolicy
type ClusterOverridePolicyList ¶ added in v0.4.0
type ClusterOverridePolicyList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` // Items holds a list of ClusterOverridePolicy. Items []ClusterOverridePolicy `json:"items"` }
ClusterOverridePolicyList is a collection of ClusterOverridePolicy.
func (*ClusterOverridePolicyList) DeepCopy ¶ added in v0.4.0
func (in *ClusterOverridePolicyList) DeepCopy() *ClusterOverridePolicyList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterOverridePolicyList.
func (*ClusterOverridePolicyList) DeepCopyInto ¶ added in v0.4.0
func (in *ClusterOverridePolicyList) DeepCopyInto(out *ClusterOverridePolicyList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ClusterOverridePolicyList) DeepCopyObject ¶ added in v0.4.0
func (in *ClusterOverridePolicyList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ClusterPreferences ¶ added in v0.5.0
type ClusterPreferences struct { // StaticWeightList defines the static cluster weight. // +optional StaticWeightList []StaticClusterWeight `json:"staticWeightList,omitempty"` // DynamicWeight specifies the factor to generates dynamic weight list. // If specified, StaticWeightList will be ignored. // +kubebuilder:validation:Enum=AvailableReplicas // +optional DynamicWeight DynamicWeightFactor `json:"dynamicWeight,omitempty"` }
ClusterPreferences describes weight for each cluster or for each group of cluster.
func (*ClusterPreferences) DeepCopy ¶ added in v0.5.0
func (in *ClusterPreferences) DeepCopy() *ClusterPreferences
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterPreferences.
func (*ClusterPreferences) DeepCopyInto ¶ added in v0.5.0
func (in *ClusterPreferences) DeepCopyInto(out *ClusterPreferences)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ClusterPropagationPolicy ¶ added in v0.4.0
type ClusterPropagationPolicy struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` // Spec represents the desired behavior of ClusterPropagationPolicy. // +required Spec PropagationSpec `json:"spec"` }
ClusterPropagationPolicy represents the cluster-wide policy that propagates a group of resources to one or more clusters. Different with PropagationPolicy that could only propagate resources in its own namespace, ClusterPropagationPolicy is able to propagate cluster level resources and resources in any namespace other than system reserved ones. System reserved namespaces are: karmada-system, karmada-cluster, karmada-es-*.
func (*ClusterPropagationPolicy) DeepCopy ¶ added in v0.4.0
func (in *ClusterPropagationPolicy) DeepCopy() *ClusterPropagationPolicy
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterPropagationPolicy.
func (*ClusterPropagationPolicy) DeepCopyInto ¶ added in v0.4.0
func (in *ClusterPropagationPolicy) DeepCopyInto(out *ClusterPropagationPolicy)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ClusterPropagationPolicy) DeepCopyObject ¶ added in v0.4.0
func (in *ClusterPropagationPolicy) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*ClusterPropagationPolicy) ExplicitPriority ¶ added in v1.4.0
func (p *ClusterPropagationPolicy) ExplicitPriority() int32
ExplicitPriority returns the explicit priority of a ClusterPropagationPolicy.
type ClusterPropagationPolicyList ¶ added in v0.4.0
type ClusterPropagationPolicyList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []ClusterPropagationPolicy `json:"items"` }
ClusterPropagationPolicyList contains a list of ClusterPropagationPolicy.
func (*ClusterPropagationPolicyList) DeepCopy ¶ added in v0.4.0
func (in *ClusterPropagationPolicyList) DeepCopy() *ClusterPropagationPolicyList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterPropagationPolicyList.
func (*ClusterPropagationPolicyList) DeepCopyInto ¶ added in v0.4.0
func (in *ClusterPropagationPolicyList) DeepCopyInto(out *ClusterPropagationPolicyList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ClusterPropagationPolicyList) DeepCopyObject ¶ added in v0.4.0
func (in *ClusterPropagationPolicyList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ClusterQuotaStatus ¶ added in v1.1.0
type ClusterQuotaStatus struct { // ClusterName is the name of the cluster the limits enforce to. // +required ClusterName string `json:"clusterName"` corev1.ResourceQuotaStatus `json:",inline"` }
ClusterQuotaStatus represents the set of desired limits and observed usage for a specific cluster.
func (*ClusterQuotaStatus) DeepCopy ¶ added in v1.1.0
func (in *ClusterQuotaStatus) DeepCopy() *ClusterQuotaStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterQuotaStatus.
func (*ClusterQuotaStatus) DeepCopyInto ¶ added in v1.1.0
func (in *ClusterQuotaStatus) DeepCopyInto(out *ClusterQuotaStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type CommandArgsOverrider ¶ added in v0.8.0
type CommandArgsOverrider struct { // The name of container // +required ContainerName string `json:"containerName"` // Operator represents the operator which will apply on the command/args. // +kubebuilder:validation:Enum=add;remove // +required Operator OverriderOperator `json:"operator"` // Value to be applied to command/args. // Items in Value which will be appended after command/args when Operator is 'add'. // Items in Value which match in command/args will be deleted when Operator is 'remove'. // If Value is empty, then the command/args will remain the same. // +optional Value []string `json:"value,omitempty"` }
CommandArgsOverrider represents the rules dedicated to handling command/args overrides.
func (*CommandArgsOverrider) DeepCopy ¶ added in v0.9.0
func (in *CommandArgsOverrider) DeepCopy() *CommandArgsOverrider
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CommandArgsOverrider.
func (*CommandArgsOverrider) DeepCopyInto ¶ added in v0.9.0
func (in *CommandArgsOverrider) DeepCopyInto(out *CommandArgsOverrider)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type DynamicWeightFactor ¶ added in v0.10.0
type DynamicWeightFactor string
DynamicWeightFactor represents the weight factor. For now only support 'AvailableReplicas', more factors could be extended if there is a need.
const ( // DynamicWeightByAvailableReplicas represents the cluster weight list should be generated according to // available resource (available replicas). // Example: // The scheduler selected 3 clusters (A/B/C) and should divide 12 replicas to them. // Workload: // Desired replica: 12 // Cluster: // A: Max available replica: 6 // B: Max available replica: 12 // C: Max available replica: 18 // The weight of cluster A:B:C will be 6:12:18 (equals to 1:2:3). At last, the assignment would be 'A: 2, B: 4, C: 6'. DynamicWeightByAvailableReplicas DynamicWeightFactor = "AvailableReplicas" )
type FederatedResourceQuota ¶ added in v1.1.0
type FederatedResourceQuota struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` // Spec defines the desired quota. // +required Spec FederatedResourceQuotaSpec `json:"spec"` // Status defines the actual enforced quota and its current usage. // +optional Status FederatedResourceQuotaStatus `json:"status,omitempty"` }
FederatedResourceQuota sets aggregate quota restrictions enforced per namespace across all clusters.
func (*FederatedResourceQuota) DeepCopy ¶ added in v1.1.0
func (in *FederatedResourceQuota) DeepCopy() *FederatedResourceQuota
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FederatedResourceQuota.
func (*FederatedResourceQuota) DeepCopyInto ¶ added in v1.1.0
func (in *FederatedResourceQuota) DeepCopyInto(out *FederatedResourceQuota)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*FederatedResourceQuota) DeepCopyObject ¶ added in v1.1.0
func (in *FederatedResourceQuota) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type FederatedResourceQuotaList ¶ added in v1.1.0
type FederatedResourceQuotaList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []FederatedResourceQuota `json:"items"` }
FederatedResourceQuotaList contains a list of FederatedResourceQuota.
func (*FederatedResourceQuotaList) DeepCopy ¶ added in v1.1.0
func (in *FederatedResourceQuotaList) DeepCopy() *FederatedResourceQuotaList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FederatedResourceQuotaList.
func (*FederatedResourceQuotaList) DeepCopyInto ¶ added in v1.1.0
func (in *FederatedResourceQuotaList) DeepCopyInto(out *FederatedResourceQuotaList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*FederatedResourceQuotaList) DeepCopyObject ¶ added in v1.1.0
func (in *FederatedResourceQuotaList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type FederatedResourceQuotaSpec ¶ added in v1.1.0
type FederatedResourceQuotaSpec struct { // Overall is the set of desired hard limits for each named resource. // +required Overall corev1.ResourceList `json:"overall"` // StaticAssignments represents the subset of desired hard limits for each cluster. // Note: for clusters not present in this list, Karmada will set an empty ResourceQuota to them, which means these // clusters will have no quotas in the referencing namespace. // +optional StaticAssignments []StaticClusterAssignment `json:"staticAssignments,omitempty"` }
FederatedResourceQuotaSpec defines the desired hard limits to enforce for Quota.
func (*FederatedResourceQuotaSpec) DeepCopy ¶ added in v1.1.0
func (in *FederatedResourceQuotaSpec) DeepCopy() *FederatedResourceQuotaSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FederatedResourceQuotaSpec.
func (*FederatedResourceQuotaSpec) DeepCopyInto ¶ added in v1.1.0
func (in *FederatedResourceQuotaSpec) DeepCopyInto(out *FederatedResourceQuotaSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type FederatedResourceQuotaStatus ¶ added in v1.1.0
type FederatedResourceQuotaStatus struct { // Overall is the set of enforced hard limits for each named resource. // +optional Overall corev1.ResourceList `json:"overall,omitempty"` // OverallUsed is the current observed total usage of the resource in the namespace. // +optional OverallUsed corev1.ResourceList `json:"overallUsed,omitempty"` // AggregatedStatus is the observed quota usage of each cluster. // +optional AggregatedStatus []ClusterQuotaStatus `json:"aggregatedStatus,omitempty"` }
FederatedResourceQuotaStatus defines the enforced hard limits and observed use.
func (*FederatedResourceQuotaStatus) DeepCopy ¶ added in v1.1.0
func (in *FederatedResourceQuotaStatus) DeepCopy() *FederatedResourceQuotaStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FederatedResourceQuotaStatus.
func (*FederatedResourceQuotaStatus) DeepCopyInto ¶ added in v1.1.0
func (in *FederatedResourceQuotaStatus) DeepCopyInto(out *FederatedResourceQuotaStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type FieldSelector ¶
type FieldSelector struct { // A list of field selector requirements. MatchExpressions []corev1.NodeSelectorRequirement `json:"matchExpressions,omitempty"` }
FieldSelector is a field filter.
func (*FieldSelector) DeepCopy ¶
func (in *FieldSelector) DeepCopy() *FieldSelector
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FieldSelector.
func (*FieldSelector) DeepCopyInto ¶
func (in *FieldSelector) DeepCopyInto(out *FieldSelector)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ImageComponent ¶ added in v0.5.0
type ImageComponent string
ImageComponent indicates the components for image.
const ( // Registry is the registry component of an image with format '[registry/]repository[:tag]'. Registry ImageComponent = "Registry" // Repository is the repository component of an image with format '[registry/]repository[:tag]'. Repository ImageComponent = "Repository" // Tag is the tag component of an image with format '[registry/]repository[:tag]'. Tag ImageComponent = "Tag" )
type ImageOverrider ¶ added in v0.5.0
type ImageOverrider struct { // Predicate filters images before applying the rule. // // Defaults to nil, in that case, the system will automatically detect image fields if the resource type is // Pod, ReplicaSet, Deployment, StatefulSet, DaemonSet or Job by following rule: // - Pod: spec/containers/<N>/image // - ReplicaSet: spec/template/spec/containers/<N>/image // - Deployment: spec/template/spec/containers/<N>/image // - DaemonSet: spec/template/spec/containers/<N>/image // - StatefulSet: spec/template/spec/containers/<N>/image // - Job: spec/template/spec/containers/<N>/image // In addition, all images will be processed if the resource object has more than one container. // // If not nil, only images matches the filters will be processed. // +optional Predicate *ImagePredicate `json:"predicate,omitempty"` // Component is part of image name. // Basically we presume an image can be made of '[registry/]repository[:tag]'. // The registry could be: // - k8s.gcr.io // - fictional.registry.example:10443 // The repository could be: // - kube-apiserver // - fictional/nginx // The tag cloud be: // - latest // - v1.19.1 // - @sha256:dbcc1c35ac38df41fd2f5e4130b32ffdb93ebae8b3dbe638c23575912276fc9c // // +kubebuilder:validation:Enum=Registry;Repository;Tag // +required Component ImageComponent `json:"component"` // Operator represents the operator which will apply on the image. // +kubebuilder:validation:Enum=add;remove;replace // +required Operator OverriderOperator `json:"operator"` // Value to be applied to image. // Must not be empty when operator is 'add' or 'replace'. // Defaults to empty and ignored when operator is 'remove'. // +optional Value string `json:"value,omitempty"` }
ImageOverrider represents the rules dedicated to handling image overrides.
func (*ImageOverrider) DeepCopy ¶ added in v0.5.0
func (in *ImageOverrider) DeepCopy() *ImageOverrider
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImageOverrider.
func (*ImageOverrider) DeepCopyInto ¶ added in v0.5.0
func (in *ImageOverrider) DeepCopyInto(out *ImageOverrider)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ImagePredicate ¶ added in v0.5.0
type ImagePredicate struct { // Path indicates the path of target field // +required Path string `json:"path"` }
ImagePredicate describes images filter.
func (*ImagePredicate) DeepCopy ¶ added in v0.5.0
func (in *ImagePredicate) DeepCopy() *ImagePredicate
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImagePredicate.
func (*ImagePredicate) DeepCopyInto ¶ added in v0.5.0
func (in *ImagePredicate) DeepCopyInto(out *ImagePredicate)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LabelAnnotationOverrider ¶ added in v1.4.0
type LabelAnnotationOverrider struct { // Operator represents the operator which will apply on the workload. // +kubebuilder:validation:Enum=add;remove;replace // +required Operator OverriderOperator `json:"operator"` // Value to be applied to annotations/labels of workload. // Items in Value which will be appended after annotations/labels when Operator is 'add'. // Items in Value which match in annotations/labels will be deleted when Operator is 'remove'. // Items in Value which match in annotations/labels will be replaced when Operator is 'replace'. // +required Value map[string]string `json:"value,omitempty"` }
LabelAnnotationOverrider represents the rules dedicated to handling workload labels/annotations
func (*LabelAnnotationOverrider) DeepCopy ¶ added in v1.4.0
func (in *LabelAnnotationOverrider) DeepCopy() *LabelAnnotationOverrider
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LabelAnnotationOverrider.
func (*LabelAnnotationOverrider) DeepCopyInto ¶ added in v1.4.0
func (in *LabelAnnotationOverrider) DeepCopyInto(out *LabelAnnotationOverrider)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type OverridePolicy ¶
type OverridePolicy struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` // Spec represents the desired behavior of OverridePolicy. Spec OverrideSpec `json:"spec"` }
OverridePolicy represents the policy that overrides a group of resources to one or more clusters.
func (*OverridePolicy) DeepCopy ¶
func (in *OverridePolicy) DeepCopy() *OverridePolicy
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OverridePolicy.
func (*OverridePolicy) DeepCopyInto ¶
func (in *OverridePolicy) DeepCopyInto(out *OverridePolicy)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*OverridePolicy) DeepCopyObject ¶
func (in *OverridePolicy) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*OverridePolicy) GetName ¶ added in v1.0.0
func (p *OverridePolicy) GetName() string
GetName returns the name of OverridePolicy
func (*OverridePolicy) GetNamespace ¶ added in v1.0.0
func (p *OverridePolicy) GetNamespace() string
GetNamespace returns the namespace of OverridePolicy
func (*OverridePolicy) GetOverrideSpec ¶ added in v1.0.0
func (p *OverridePolicy) GetOverrideSpec() OverrideSpec
GetOverrideSpec returns the OverrideSpec of OverridePolicy
type OverridePolicyList ¶
type OverridePolicyList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` // Items holds a list of OverridePolicy. Items []OverridePolicy `json:"items"` }
OverridePolicyList is a collection of OverridePolicy.
func (*OverridePolicyList) DeepCopy ¶
func (in *OverridePolicyList) DeepCopy() *OverridePolicyList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OverridePolicyList.
func (*OverridePolicyList) DeepCopyInto ¶
func (in *OverridePolicyList) DeepCopyInto(out *OverridePolicyList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*OverridePolicyList) DeepCopyObject ¶
func (in *OverridePolicyList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type OverrideSpec ¶
type OverrideSpec struct { // ResourceSelectors restricts resource types that this override policy applies to. // nil means matching all resources. // +optional ResourceSelectors []ResourceSelector `json:"resourceSelectors,omitempty"` // OverrideRules defines a collection of override rules on target clusters. // +optional OverrideRules []RuleWithCluster `json:"overrideRules,omitempty"` // TargetCluster defines restrictions on this override policy // that only applies to resources propagated to the matching clusters. // nil means matching all clusters. // // Deprecated: This filed is deprecated in v1.0 and please use the OverrideRules instead. // +optional TargetCluster *ClusterAffinity `json:"targetCluster,omitempty"` // Overriders represents the override rules that would apply on resources // // Deprecated: This filed is deprecated in v1.0 and please use the OverrideRules instead. // +optional Overriders Overriders `json:"overriders"` }
OverrideSpec defines the desired behavior of OverridePolicy.
func (*OverrideSpec) DeepCopy ¶
func (in *OverrideSpec) DeepCopy() *OverrideSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OverrideSpec.
func (*OverrideSpec) DeepCopyInto ¶
func (in *OverrideSpec) DeepCopyInto(out *OverrideSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type OverriderOperator ¶
type OverriderOperator string
OverriderOperator is the set of operators that can be used in an overrider.
const ( OverriderOpAdd OverriderOperator = "add" OverriderOpRemove OverriderOperator = "remove" OverriderOpReplace OverriderOperator = "replace" )
These are valid overrider operators.
type Overriders ¶
type Overriders struct { // Plaintext represents override rules defined with plaintext overriders. // +optional Plaintext []PlaintextOverrider `json:"plaintext,omitempty"` // ImageOverrider represents the rules dedicated to handling image overrides. // +optional ImageOverrider []ImageOverrider `json:"imageOverrider,omitempty"` // CommandOverrider represents the rules dedicated to handling container command // +optional CommandOverrider []CommandArgsOverrider `json:"commandOverrider,omitempty"` // ArgsOverrider represents the rules dedicated to handling container args // +optional ArgsOverrider []CommandArgsOverrider `json:"argsOverrider,omitempty"` // LabelsOverrider represents the rules dedicated to handling workload labels // +optional LabelsOverrider []LabelAnnotationOverrider `json:"labelsOverrider,omitempty"` // AnnotationsOverrider represents the rules dedicated to handling workload annotations // +optional AnnotationsOverrider []LabelAnnotationOverrider `json:"annotationsOverrider,omitempty"` }
Overriders offers various alternatives to represent the override rules.
If more than one alternative exists, they will be applied with following order: - ImageOverrider - CommandOverrider - ArgsOverrider - LabelsOverrider - AnnotationsOverrider - Plaintext
func (*Overriders) DeepCopy ¶
func (in *Overriders) DeepCopy() *Overriders
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Overriders.
func (*Overriders) DeepCopyInto ¶
func (in *Overriders) DeepCopyInto(out *Overriders)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Placement ¶
type Placement struct { // ClusterAffinity represents scheduling restrictions to a certain set of clusters. // If not set, any cluster can be scheduling candidate. // +optional ClusterAffinity *ClusterAffinity `json:"clusterAffinity,omitempty"` // ClusterTolerations represents the tolerations. // +optional ClusterTolerations []corev1.Toleration `json:"clusterTolerations,omitempty"` // SpreadConstraints represents a list of the scheduling constraints. // +optional SpreadConstraints []SpreadConstraint `json:"spreadConstraints,omitempty"` // ReplicaScheduling represents the scheduling policy on dealing with the number of replicas // when propagating resources that have replicas in spec (e.g. deployments, statefulsets) to member clusters. // +optional ReplicaScheduling *ReplicaSchedulingStrategy `json:"replicaScheduling,omitempty"` }
Placement represents the rule for select clusters.
func (*Placement) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Placement.
func (*Placement) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type PlaintextOverrider ¶
type PlaintextOverrider struct { // Path indicates the path of target field Path string `json:"path"` // Operator indicates the operation on target field. // Available operators are: add, replace and remove. // +kubebuilder:validation:Enum=add;remove;replace Operator OverriderOperator `json:"operator"` // Value to be applied to target field. // Must be empty when operator is Remove. // +optional Value apiextensionsv1.JSON `json:"value,omitempty"` }
PlaintextOverrider is a simple overrider that overrides target fields according to path, operator and value.
func (*PlaintextOverrider) DeepCopy ¶
func (in *PlaintextOverrider) DeepCopy() *PlaintextOverrider
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PlaintextOverrider.
func (*PlaintextOverrider) DeepCopyInto ¶
func (in *PlaintextOverrider) DeepCopyInto(out *PlaintextOverrider)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type PropagationPolicy ¶
type PropagationPolicy struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` // Spec represents the desired behavior of PropagationPolicy. // +required Spec PropagationSpec `json:"spec"` }
PropagationPolicy represents the policy that propagates a group of resources to one or more clusters.
func (*PropagationPolicy) DeepCopy ¶
func (in *PropagationPolicy) DeepCopy() *PropagationPolicy
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PropagationPolicy.
func (*PropagationPolicy) DeepCopyInto ¶
func (in *PropagationPolicy) DeepCopyInto(out *PropagationPolicy)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*PropagationPolicy) DeepCopyObject ¶
func (in *PropagationPolicy) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*PropagationPolicy) ExplicitPriority ¶ added in v1.4.0
func (p *PropagationPolicy) ExplicitPriority() int32
ExplicitPriority returns the explicit priority of a PropagationPolicy.
type PropagationPolicyList ¶
type PropagationPolicyList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []PropagationPolicy `json:"items"` }
PropagationPolicyList contains a list of PropagationPolicy.
func (*PropagationPolicyList) DeepCopy ¶
func (in *PropagationPolicyList) DeepCopy() *PropagationPolicyList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PropagationPolicyList.
func (*PropagationPolicyList) DeepCopyInto ¶
func (in *PropagationPolicyList) DeepCopyInto(out *PropagationPolicyList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*PropagationPolicyList) DeepCopyObject ¶
func (in *PropagationPolicyList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type PropagationSpec ¶
type PropagationSpec struct { // ResourceSelectors used to select resources. // Nil or empty selector is not allowed and doesn't mean match all kinds // of resources for security concerns that sensitive resources(like Secret) // might be accidentally propagated. // +required // +kubebuilder:validation:MinItems=1 ResourceSelectors []ResourceSelector `json:"resourceSelectors"` // Association tells if relevant resources should be selected automatically. // e.g. a ConfigMap referred by a Deployment. // default false. // Deprecated: in favor of PropagateDeps. // +optional Association bool `json:"association,omitempty"` // PropagateDeps tells if relevant resources should be propagated automatically. // Take 'Deployment' which referencing 'ConfigMap' and 'Secret' as an example, when 'propagateDeps' is 'true', // the referencing resources could be omitted(for saving config effort) from 'resourceSelectors' as they will be // propagated along with the Deployment. In addition to the propagating process, the referencing resources will be // migrated along with the Deployment in the fail-over scenario. // // Defaults to false. // +optional PropagateDeps bool `json:"propagateDeps,omitempty"` // Placement represents the rule for select clusters to propagate resources. // +optional Placement Placement `json:"placement,omitempty"` // Priority indicates the importance of a policy(PropagationPolicy or ClusterPropagationPolicy). // A policy will be applied for the matched resource templates if there is // no other policies with higher priority at the point of the resource // template be processed. // Once a resource template has been claimed by a policy, by default it will // not be preempted by following policies even with a higher priority. // // In case of two policies have the same priority, the one with a more precise // matching rules in ResourceSelectors wins: // - matching by name(resourceSelector.name) has higher priority than // by selector(resourceSelector.labelSelector) // - matching by selector(resourceSelector.labelSelector) has higher priority // than by APIVersion(resourceSelector.apiVersion) and Kind(resourceSelector.kind). // If there is still no winner at this point, the one with the lower alphabetic // order wins, e.g. policy 'bar' has higher priority than 'foo'. // // The higher the value, the higher the priority. Defaults to zero. // +optional // +kubebuilder:default=0 Priority *int32 `json:"priority,omitempty"` // DependentOverrides represents the list of overrides(OverridePolicy) // which must present before the current PropagationPolicy takes effect. // // It used to explicitly specify overrides which current PropagationPolicy rely on. // A typical scenario is the users create OverridePolicy(ies) and resources at the same time, // they want to ensure the new-created policies would be adopted. // // Note: For the overrides, OverridePolicy(ies) in current namespace and ClusterOverridePolicy(ies), // which not present in this list will still be applied if they matches the resources. // +optional DependentOverrides []string `json:"dependentOverrides,omitempty"` // SchedulerName represents which scheduler to proceed the scheduling. // If specified, the policy will be dispatched by specified scheduler. // If not specified, the policy will be dispatched by default scheduler. // +optional SchedulerName string `json:"schedulerName,omitempty"` }
PropagationSpec represents the desired behavior of PropagationPolicy.
func (*PropagationSpec) DeepCopy ¶
func (in *PropagationSpec) DeepCopy() *PropagationSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PropagationSpec.
func (*PropagationSpec) DeepCopyInto ¶
func (in *PropagationSpec) DeepCopyInto(out *PropagationSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*PropagationSpec) ExplicitPriority ¶ added in v1.4.0
func (p *PropagationSpec) ExplicitPriority() int32
ExplicitPriority returns the explicit priority declared by '.spec.Priority'.
type ReplicaDivisionPreference ¶ added in v0.7.0
type ReplicaDivisionPreference string
ReplicaDivisionPreference describes options of how replicas can be scheduled.
const ( // ReplicaDivisionPreferenceAggregated divides replicas into clusters as few as possible, // while respecting clusters' resource availabilities during the division. ReplicaDivisionPreferenceAggregated ReplicaDivisionPreference = "Aggregated" // ReplicaDivisionPreferenceWeighted divides replicas by weight according to WeightPreference. ReplicaDivisionPreferenceWeighted ReplicaDivisionPreference = "Weighted" )
type ReplicaSchedulingStrategy ¶ added in v0.7.0
type ReplicaSchedulingStrategy struct { // ReplicaSchedulingType determines how the replicas is scheduled when karmada propagating // a resource. Valid options are Duplicated and Divided. // "Duplicated" duplicates the same replicas to each candidate member cluster from resource. // "Divided" divides replicas into parts according to number of valid candidate member // clusters, and exact replicas for each cluster are determined by ReplicaDivisionPreference. // +kubebuilder:validation:Enum=Duplicated;Divided // +optional ReplicaSchedulingType ReplicaSchedulingType `json:"replicaSchedulingType,omitempty"` // ReplicaDivisionPreference determines how the replicas is divided // when ReplicaSchedulingType is "Divided". Valid options are Aggregated and Weighted. // "Aggregated" divides replicas into clusters as few as possible, // while respecting clusters' resource availabilities during the division. // "Weighted" divides replicas by weight according to WeightPreference. // +kubebuilder:validation:Enum=Aggregated;Weighted // +optional ReplicaDivisionPreference ReplicaDivisionPreference `json:"replicaDivisionPreference,omitempty"` // WeightPreference describes weight for each cluster or for each group of cluster // If ReplicaDivisionPreference is set to "Weighted", and WeightPreference is not set, scheduler will weight all clusters the same. // +optional WeightPreference *ClusterPreferences `json:"weightPreference,omitempty"` }
ReplicaSchedulingStrategy represents the assignment strategy of replicas.
func (*ReplicaSchedulingStrategy) DeepCopy ¶ added in v0.7.0
func (in *ReplicaSchedulingStrategy) DeepCopy() *ReplicaSchedulingStrategy
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ReplicaSchedulingStrategy.
func (*ReplicaSchedulingStrategy) DeepCopyInto ¶ added in v0.7.0
func (in *ReplicaSchedulingStrategy) DeepCopyInto(out *ReplicaSchedulingStrategy)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ReplicaSchedulingType ¶ added in v0.7.0
type ReplicaSchedulingType string
ReplicaSchedulingType describes scheduling methods for the "replicas" in a resource.
const ( // ReplicaSchedulingTypeDuplicated means when propagating a resource, // each candidate member cluster will directly apply the original replicas. ReplicaSchedulingTypeDuplicated ReplicaSchedulingType = "Duplicated" // ReplicaSchedulingTypeDivided means when propagating a resource, // each candidate member cluster will get only a part of original replicas. ReplicaSchedulingTypeDivided ReplicaSchedulingType = "Divided" )
type ResourceSelector ¶
type ResourceSelector struct { // APIVersion represents the API version of the target resources. // +required APIVersion string `json:"apiVersion"` // Kind represents the Kind of the target resources. // +required Kind string `json:"kind"` // Namespace of the target resource. // Default is empty, which means inherit from the parent object scope. // +optional Namespace string `json:"namespace,omitempty"` // Name of the target resource. // Default is empty, which means selecting all resources. // +optional Name string `json:"name,omitempty"` // A label query over a set of resources. // If name is not empty, labelSelector will be ignored. // +optional LabelSelector *metav1.LabelSelector `json:"labelSelector,omitempty"` }
ResourceSelector the resources will be selected.
func (*ResourceSelector) DeepCopy ¶
func (in *ResourceSelector) DeepCopy() *ResourceSelector
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ResourceSelector.
func (*ResourceSelector) DeepCopyInto ¶
func (in *ResourceSelector) DeepCopyInto(out *ResourceSelector)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type RuleWithCluster ¶ added in v1.0.0
type RuleWithCluster struct { // TargetCluster defines restrictions on this override policy // that only applies to resources propagated to the matching clusters. // nil means matching all clusters. // +optional TargetCluster *ClusterAffinity `json:"targetCluster,omitempty"` // Overriders represents the override rules that would apply on resources // +required Overriders Overriders `json:"overriders"` }
RuleWithCluster defines the override rules on clusters.
func (*RuleWithCluster) DeepCopy ¶ added in v1.0.0
func (in *RuleWithCluster) DeepCopy() *RuleWithCluster
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RuleWithCluster.
func (*RuleWithCluster) DeepCopyInto ¶ added in v1.0.0
func (in *RuleWithCluster) DeepCopyInto(out *RuleWithCluster)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SpreadConstraint ¶
type SpreadConstraint struct { // SpreadByField represents the fields on Karmada cluster API used for // dynamically grouping member clusters into different groups. // Resources will be spread among different cluster groups. // Available fields for spreading are: cluster, region, zone, and provider. // SpreadByField should not co-exist with SpreadByLabel. // If both SpreadByField and SpreadByLabel are empty, SpreadByField will be set to "cluster" by system. // +kubebuilder:validation:Enum=cluster;region;zone;provider // +optional SpreadByField SpreadFieldValue `json:"spreadByField,omitempty"` // SpreadByLabel represents the label key used for // grouping member clusters into different groups. // Resources will be spread among different cluster groups. // SpreadByLabel should not co-exist with SpreadByField. // +optional SpreadByLabel string `json:"spreadByLabel,omitempty"` // MaxGroups restricts the maximum number of cluster groups to be selected. // +optional MaxGroups int `json:"maxGroups,omitempty"` // MinGroups restricts the minimum number of cluster groups to be selected. // Defaults to 1. // +optional MinGroups int `json:"minGroups,omitempty"` }
SpreadConstraint represents the spread constraints on resources.
func (*SpreadConstraint) DeepCopy ¶
func (in *SpreadConstraint) DeepCopy() *SpreadConstraint
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SpreadConstraint.
func (*SpreadConstraint) DeepCopyInto ¶
func (in *SpreadConstraint) DeepCopyInto(out *SpreadConstraint)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SpreadFieldValue ¶
type SpreadFieldValue string
SpreadFieldValue is the type to define valid values for SpreadConstraint.SpreadByField
const ( SpreadByFieldCluster SpreadFieldValue = "cluster" SpreadByFieldRegion SpreadFieldValue = "region" SpreadByFieldZone SpreadFieldValue = "zone" SpreadByFieldProvider SpreadFieldValue = "provider" )
Available fields for spreading are: cluster, region, zone, and provider.
type StaticClusterAssignment ¶ added in v1.1.0
type StaticClusterAssignment struct { // ClusterName is the name of the cluster the limits enforce to. // +required ClusterName string `json:"clusterName"` // Hard is the set of desired hard limits for each named resource. // +required Hard corev1.ResourceList `json:"hard"` }
StaticClusterAssignment represents the set of desired hard limits for a specific cluster.
func (*StaticClusterAssignment) DeepCopy ¶ added in v1.1.0
func (in *StaticClusterAssignment) DeepCopy() *StaticClusterAssignment
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StaticClusterAssignment.
func (*StaticClusterAssignment) DeepCopyInto ¶ added in v1.1.0
func (in *StaticClusterAssignment) DeepCopyInto(out *StaticClusterAssignment)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type StaticClusterWeight ¶ added in v0.5.0
type StaticClusterWeight struct { // TargetCluster describes the filter to select clusters. // +required TargetCluster ClusterAffinity `json:"targetCluster"` // Weight expressing the preference to the cluster(s) specified by 'TargetCluster'. // +kubebuilder:validation:Minimum=1 // +required Weight int64 `json:"weight"` }
StaticClusterWeight defines the static cluster weight.
func (*StaticClusterWeight) DeepCopy ¶ added in v0.5.0
func (in *StaticClusterWeight) DeepCopy() *StaticClusterWeight
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StaticClusterWeight.
func (*StaticClusterWeight) DeepCopyInto ¶ added in v0.5.0
func (in *StaticClusterWeight) DeepCopyInto(out *StaticClusterWeight)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.