Documentation ¶
Overview ¶
+k8s:openapi-gen=true +k8s:deepcopy-gen=package,register +groupName=karpenter.k8s.alicloud
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ( TerminationFinalizer = apis.Group + "/termination" AWSToKubeArchitectures = map[string]string{ "x86_64": karpv1.ArchitectureAmd64, karpv1.ArchitectureArm64: karpv1.ArchitectureArm64, } WellKnownArchitectures = sets.NewString( karpv1.ArchitectureAmd64, karpv1.ArchitectureArm64, ) RestrictedLabelDomains = []string{ apis.Group, } RestrictedTagPatterns = []*regexp.Regexp{ regexp.MustCompile(`^kubernetes\.io/cluster/[0-9A-Za-z][A-Za-z0-9\-_]*$`), regexp.MustCompile(fmt.Sprintf("^%s$", regexp.QuoteMeta(karpv1.NodePoolLabelKey))), regexp.MustCompile(fmt.Sprintf("^%s$", regexp.QuoteMeta(EKSClusterNameTagKey))), regexp.MustCompile(fmt.Sprintf("^%s$", regexp.QuoteMeta(LabelNodeClass))), regexp.MustCompile(fmt.Sprintf("^%s$", regexp.QuoteMeta(TagNodeClaim))), } AMIFamilyBottlerocket = "Bottlerocket" AMIFamilyAL2 = "AL2" AMIFamilyAL2023 = "AL2023" AMIFamilyUbuntu = "Ubuntu" AMIFamilyWindows2019 = "Windows2019" AMIFamilyWindows2022 = "Windows2022" AMIFamilyCustom = "Custom" Windows2019 = "2019" Windows2022 = "2022" WindowsCore = "Core" Windows2019Build = "10.0.17763" Windows2022Build = "10.0.20348" ResourceNVIDIAGPU corev1.ResourceName = "nvidia.com/gpu" ResourceAMDGPU corev1.ResourceName = "amd.com/gpu" ResourceAWSNeuron corev1.ResourceName = "alicloud.amazon.com/neuron" ResourceHabanaGaudi corev1.ResourceName = "habana.ai/gaudi" ResourceAWSPodENI corev1.ResourceName = "vpc.amazonalicloud.com/pod-eni" ResourcePrivateIPv4Address corev1.ResourceName = "vpc.amazonalicloud.com/PrivateIPv4Address" ResourceEFA corev1.ResourceName = "vpc.amazonalicloud.com/efa" EKSClusterNameTagKey = "eks:eks-cluster-name" LabelNodeClass = apis.Group + "/ecsnodeclass" LabelTopologyZoneID = "topology.k8s.alicloud/zone-id" LabelInstanceHypervisor = apis.Group + "/instance-hypervisor" LabelInstanceEncryptionInTransitSupported = apis.Group + "/instance-encryption-in-transit-supported" LabelInstanceCategory = apis.Group + "/instance-category" LabelInstanceFamily = apis.Group + "/instance-family" LabelInstanceGeneration = apis.Group + "/instance-generation" LabelInstanceLocalNVME = apis.Group + "/instance-local-nvme" LabelInstanceSize = apis.Group + "/instance-size" LabelInstanceCPU = apis.Group + "/instance-cpu" LabelInstanceCPUManufacturer = apis.Group + "/instance-cpu-manufacturer" LabelInstanceMemory = apis.Group + "/instance-memory" LabelInstanceEBSBandwidth = apis.Group + "/instance-ebs-bandwidth" LabelInstanceNetworkBandwidth = apis.Group + "/instance-network-bandwidth" LabelInstanceGPUName = apis.Group + "/instance-gpu-name" LabelInstanceGPUManufacturer = apis.Group + "/instance-gpu-manufacturer" LabelInstanceGPUCount = apis.Group + "/instance-gpu-count" LabelInstanceGPUMemory = apis.Group + "/instance-gpu-memory" LabelInstanceAcceleratorName = apis.Group + "/instance-accelerator-name" LabelInstanceAcceleratorManufacturer = apis.Group + "/instance-accelerator-manufacturer" LabelInstanceAcceleratorCount = apis.Group + "/instance-accelerator-count" AnnotationECSNodeClassHash = apis.Group + "/ecsnodeclass-hash" AnnotationClusterNameTaggedCompatability = apis.CompatibilityGroup + "/cluster-name-tagged" AnnotationECSNodeClassHashVersion = apis.Group + "/ecsnodeclass-hash-version" AnnotationInstanceTagged = apis.Group + "/tagged" TagNodeClaim = coreapis.Group + "/nodeclaim" TagManagedLaunchTemplate = apis.Group + "/cluster" TagName = "Name" )
Functions ¶
This section is empty.
Types ¶
type ECSNodeClass ¶
type ECSNodeClass struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec ECSNodeClassSpec `json:"spec,omitempty"` Status ECSNodeClassStatus `json:"status,omitempty"` }
ECSNodeClass is the Schema for the ECSNodeClass API +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:subresource:status
func (*ECSNodeClass) DeepCopy ¶
func (in *ECSNodeClass) DeepCopy() *ECSNodeClass
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ECSNodeClass.
func (*ECSNodeClass) DeepCopyInto ¶
func (in *ECSNodeClass) DeepCopyInto(out *ECSNodeClass)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ECSNodeClass) DeepCopyObject ¶
func (in *ECSNodeClass) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*ECSNodeClass) SetDefaults ¶
func (in *ECSNodeClass) SetDefaults(_ context.Context)
type ECSNodeClassList ¶
type ECSNodeClassList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []ECSNodeClass `json:"items"` }
ECSNodeClassList contains a list of ECSNodeClass +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
func (*ECSNodeClassList) DeepCopy ¶
func (in *ECSNodeClassList) DeepCopy() *ECSNodeClassList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ECSNodeClassList.
func (*ECSNodeClassList) DeepCopyInto ¶
func (in *ECSNodeClassList) DeepCopyInto(out *ECSNodeClassList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ECSNodeClassList) DeepCopyObject ¶
func (in *ECSNodeClassList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ECSNodeClassSpec ¶
type ECSNodeClassSpec struct { }
ECSNodeClassSpec is the top level specification for the AliCloud Karpenter Provider. This will contain configuration necessary to launch instances in AliCloud.
func (*ECSNodeClassSpec) DeepCopy ¶
func (in *ECSNodeClassSpec) DeepCopy() *ECSNodeClassSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ECSNodeClassSpec.
func (*ECSNodeClassSpec) DeepCopyInto ¶
func (in *ECSNodeClassSpec) DeepCopyInto(out *ECSNodeClassSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ECSNodeClassStatus ¶
type ECSNodeClassStatus struct { }
ECSNodeClassStatus contains the resolved state of the ECSNodeClass
func (*ECSNodeClassStatus) DeepCopy ¶
func (in *ECSNodeClassStatus) DeepCopy() *ECSNodeClassStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ECSNodeClassStatus.
func (*ECSNodeClassStatus) DeepCopyInto ¶
func (in *ECSNodeClassStatus) DeepCopyInto(out *ECSNodeClassStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type KubeletConfiguration ¶
type KubeletConfiguration struct { // clusterDNS is a list of IP addresses for the cluster DNS server. // Note that not all providers may use all addresses. //+optional ClusterDNS []string `json:"clusterDNS,omitempty"` // MaxPods is an override for the maximum number of pods that can run on // a worker node instance. // +kubebuilder:validation:Minimum:=0 // +optional MaxPods *int32 `json:"maxPods,omitempty"` // PodsPerCore is an override for the number of pods that can run on a worker node // instance based on the number of cpu cores. This value cannot exceed MaxPods, so, if // MaxPods is a lower value, that value will be used. // +kubebuilder:validation:Minimum:=0 // +optional PodsPerCore *int32 `json:"podsPerCore,omitempty"` // SystemReserved contains resources reserved for OS system daemons and kernel memory. // +kubebuilder:validation:XValidation:message="valid keys for systemReserved are ['cpu','memory','ephemeral-storage','pid']",rule="self.all(x, x=='cpu' || x=='memory' || x=='ephemeral-storage' || x=='pid')" // +kubebuilder:validation:XValidation:message="systemReserved value cannot be a negative resource quantity",rule="self.all(x, !self[x].startsWith('-'))" // +optional SystemReserved map[string]string `json:"systemReserved,omitempty"` // KubeReserved contains resources reserved for Kubernetes system components. // +kubebuilder:validation:XValidation:message="valid keys for kubeReserved are ['cpu','memory','ephemeral-storage','pid']",rule="self.all(x, x=='cpu' || x=='memory' || x=='ephemeral-storage' || x=='pid')" // +kubebuilder:validation:XValidation:message="kubeReserved value cannot be a negative resource quantity",rule="self.all(x, !self[x].startsWith('-'))" // +optional KubeReserved map[string]string `json:"kubeReserved,omitempty"` // EvictionHard is the map of signal names to quantities that define hard eviction thresholds // +kubebuilder:validation:XValidation:message="valid keys for evictionHard are ['memory.available','nodefs.available','nodefs.inodesFree','imagefs.available','imagefs.inodesFree','pid.available']",rule="self.all(x, x in ['memory.available','nodefs.available','nodefs.inodesFree','imagefs.available','imagefs.inodesFree','pid.available'])" // +optional EvictionHard map[string]string `json:"evictionHard,omitempty"` // EvictionSoft is the map of signal names to quantities that define soft eviction thresholds // +kubebuilder:validation:XValidation:message="valid keys for evictionSoft are ['memory.available','nodefs.available','nodefs.inodesFree','imagefs.available','imagefs.inodesFree','pid.available']",rule="self.all(x, x in ['memory.available','nodefs.available','nodefs.inodesFree','imagefs.available','imagefs.inodesFree','pid.available'])" // +optional EvictionSoft map[string]string `json:"evictionSoft,omitempty"` // EvictionSoftGracePeriod is the map of signal names to quantities that define grace periods for each eviction signal // +kubebuilder:validation:XValidation:message="valid keys for evictionSoftGracePeriod are ['memory.available','nodefs.available','nodefs.inodesFree','imagefs.available','imagefs.inodesFree','pid.available']",rule="self.all(x, x in ['memory.available','nodefs.available','nodefs.inodesFree','imagefs.available','imagefs.inodesFree','pid.available'])" // +optional EvictionSoftGracePeriod map[string]metav1.Duration `json:"evictionSoftGracePeriod,omitempty"` // EvictionMaxPodGracePeriod is the maximum allowed grace period (in seconds) to use when terminating pods in // response to soft eviction thresholds being met. // +optional EvictionMaxPodGracePeriod *int32 `json:"evictionMaxPodGracePeriod,omitempty"` // ImageGCHighThresholdPercent is the percent of disk usage after which image // garbage collection is always run. The percent is calculated by dividing this // field value by 100, so this field must be between 0 and 100, inclusive. // When specified, the value must be greater than ImageGCLowThresholdPercent. // +kubebuilder:validation:Minimum:=0 // +kubebuilder:validation:Maximum:=100 // +optional ImageGCHighThresholdPercent *int32 `json:"imageGCHighThresholdPercent,omitempty"` // ImageGCLowThresholdPercent is the percent of disk usage before which image // garbage collection is never run. Lowest disk usage to garbage collect to. // The percent is calculated by dividing this field value by 100, // so the field value must be between 0 and 100, inclusive. // When specified, the value must be less than imageGCHighThresholdPercent // +kubebuilder:validation:Minimum:=0 // +kubebuilder:validation:Maximum:=100 // +optional ImageGCLowThresholdPercent *int32 `json:"imageGCLowThresholdPercent,omitempty"` // CPUCFSQuota enables CPU CFS quota enforcement for containers that specify CPU limits. // +optional CPUCFSQuota *bool `json:"cpuCFSQuota,omitempty"` }
KubeletConfiguration defines args to be used when configuring kubelet on provisioned nodes. They are a subset of the upstream types, recognizing not all options may be supported. Wherever possible, the types and names should reflect the upstream kubelet types. https://pkg.go.dev/k8s.io/kubelet/config/v1beta1#KubeletConfiguration https://github.com/kubernetes/kubernetes/blob/9f82d81e55cafdedab619ea25cabf5d42736dacf/cmd/kubelet/app/options/options.go#L53
func (*KubeletConfiguration) DeepCopy ¶
func (in *KubeletConfiguration) DeepCopy() *KubeletConfiguration
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KubeletConfiguration.
func (*KubeletConfiguration) DeepCopyInto ¶
func (in *KubeletConfiguration) DeepCopyInto(out *KubeletConfiguration)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.