Add support for --experimental-allocatable-ignore-eviction kubelet flag

This commit is contained in:
Ciprian Hacman 2023-08-26 06:01:27 +03:00
parent 642fd00488
commit c291190674
10 changed files with 37 additions and 0 deletions

View File

@ -3741,6 +3741,10 @@ spec:
description: Comma-delimited list of grace periods for each soft
eviction signal. For example, 'memory.available=30s'.
type: string
experimentalAllocatableIgnoreEviction:
description: ExperimentalAllocatableIgnoreEviction enables ignoring
Hard Eviction Thresholds while calculating Node Allocatable
type: boolean
experimentalAllowedUnsafeSysctls:
description: ExperimentalAllowedUnsafeSysctls are passed to the
kubelet config to whitelist allowable sysctls Was promoted to
@ -4174,6 +4178,10 @@ spec:
description: Comma-delimited list of grace periods for each soft
eviction signal. For example, 'memory.available=30s'.
type: string
experimentalAllocatableIgnoreEviction:
description: ExperimentalAllocatableIgnoreEviction enables ignoring
Hard Eviction Thresholds while calculating Node Allocatable
type: boolean
experimentalAllowedUnsafeSysctls:
description: ExperimentalAllowedUnsafeSysctls are passed to the
kubelet config to whitelist allowable sysctls Was promoted to

View File

@ -534,6 +534,10 @@ spec:
description: Comma-delimited list of grace periods for each soft
eviction signal. For example, 'memory.available=30s'.
type: string
experimentalAllocatableIgnoreEviction:
description: ExperimentalAllocatableIgnoreEviction enables ignoring
Hard Eviction Thresholds while calculating Node Allocatable
type: boolean
experimentalAllowedUnsafeSysctls:
description: ExperimentalAllowedUnsafeSysctls are passed to the
kubelet config to whitelist allowable sysctls Was promoted to

View File

@ -225,6 +225,8 @@ type KubeletConfigSpec struct {
EnableCadvisorJsonEndpoints *bool `json:"enableCadvisorJsonEndpoints,omitempty" flag:"enable-cadvisor-json-endpoints"`
// PodPidsLimit is the maximum number of pids in any pod.
PodPidsLimit *int64 `json:"podPidsLimit,omitempty" flag:"pod-max-pids"`
// ExperimentalAllocatableIgnoreEviction enables ignoring Hard Eviction Thresholds while calculating Node Allocatable
ExperimentalAllocatableIgnoreEviction *bool `json:"experimentalAllocatableIgnoreEviction,omitempty" flag:"experimental-allocatable-ignore-eviction"`
// ShutdownGracePeriod specifies the total duration that the node should delay the shutdown by.
// Default: 30s

View File

@ -225,6 +225,8 @@ type KubeletConfigSpec struct {
EnableCadvisorJsonEndpoints *bool `json:"enableCadvisorJsonEndpoints,omitempty" flag:"enable-cadvisor-json-endpoints"`
// PodPidsLimit is the maximum number of pids in any pod.
PodPidsLimit *int64 `json:"podPidsLimit,omitempty" flag:"pod-max-pids"`
// ExperimentalAllocatableIgnoreEviction enables ignoring Hard Eviction Thresholds while calculating Node Allocatable
ExperimentalAllocatableIgnoreEviction *bool `json:"experimentalAllocatableIgnoreEviction,omitempty" flag:"experimental-allocatable-ignore-eviction"`
// ShutdownGracePeriod specifies the total duration that the node should delay the shutdown by.
// Default: 30s

View File

@ -5397,6 +5397,7 @@ func autoConvert_v1alpha2_KubeletConfigSpec_To_kops_KubeletConfigSpec(in *Kubele
out.ContainerLogMaxFiles = in.ContainerLogMaxFiles
out.EnableCadvisorJsonEndpoints = in.EnableCadvisorJsonEndpoints
out.PodPidsLimit = in.PodPidsLimit
out.ExperimentalAllocatableIgnoreEviction = in.ExperimentalAllocatableIgnoreEviction
out.ShutdownGracePeriod = in.ShutdownGracePeriod
out.ShutdownGracePeriodCriticalPods = in.ShutdownGracePeriodCriticalPods
out.MemorySwapBehavior = in.MemorySwapBehavior
@ -5497,6 +5498,7 @@ func autoConvert_kops_KubeletConfigSpec_To_v1alpha2_KubeletConfigSpec(in *kops.K
out.ContainerLogMaxFiles = in.ContainerLogMaxFiles
out.EnableCadvisorJsonEndpoints = in.EnableCadvisorJsonEndpoints
out.PodPidsLimit = in.PodPidsLimit
out.ExperimentalAllocatableIgnoreEviction = in.ExperimentalAllocatableIgnoreEviction
out.ShutdownGracePeriod = in.ShutdownGracePeriod
out.ShutdownGracePeriodCriticalPods = in.ShutdownGracePeriodCriticalPods
out.MemorySwapBehavior = in.MemorySwapBehavior

View File

@ -3945,6 +3945,11 @@ func (in *KubeletConfigSpec) DeepCopyInto(out *KubeletConfigSpec) {
*out = new(int64)
**out = **in
}
if in.ExperimentalAllocatableIgnoreEviction != nil {
in, out := &in.ExperimentalAllocatableIgnoreEviction, &out.ExperimentalAllocatableIgnoreEviction
*out = new(bool)
**out = **in
}
if in.ShutdownGracePeriod != nil {
in, out := &in.ShutdownGracePeriod, &out.ShutdownGracePeriod
*out = new(v1.Duration)

View File

@ -223,6 +223,8 @@ type KubeletConfigSpec struct {
EnableCadvisorJsonEndpoints *bool `json:"enableCadvisorJsonEndpoints,omitempty" flag:"enable-cadvisor-json-endpoints"`
// PodPidsLimit is the maximum number of pids in any pod.
PodPidsLimit *int64 `json:"podPidsLimit,omitempty" flag:"pod-max-pids"`
// ExperimentalAllocatableIgnoreEviction enables ignoring Hard Eviction Thresholds while calculating Node Allocatable
ExperimentalAllocatableIgnoreEviction *bool `json:"experimentalAllocatableIgnoreEviction,omitempty" flag:"experimental-allocatable-ignore-eviction"`
// ShutdownGracePeriod specifies the total duration that the node should delay the shutdown by.
// Default: 30s

View File

@ -5788,6 +5788,7 @@ func autoConvert_v1alpha3_KubeletConfigSpec_To_kops_KubeletConfigSpec(in *Kubele
out.ContainerLogMaxFiles = in.ContainerLogMaxFiles
out.EnableCadvisorJsonEndpoints = in.EnableCadvisorJsonEndpoints
out.PodPidsLimit = in.PodPidsLimit
out.ExperimentalAllocatableIgnoreEviction = in.ExperimentalAllocatableIgnoreEviction
out.ShutdownGracePeriod = in.ShutdownGracePeriod
out.ShutdownGracePeriodCriticalPods = in.ShutdownGracePeriodCriticalPods
out.MemorySwapBehavior = in.MemorySwapBehavior
@ -5888,6 +5889,7 @@ func autoConvert_kops_KubeletConfigSpec_To_v1alpha3_KubeletConfigSpec(in *kops.K
out.ContainerLogMaxFiles = in.ContainerLogMaxFiles
out.EnableCadvisorJsonEndpoints = in.EnableCadvisorJsonEndpoints
out.PodPidsLimit = in.PodPidsLimit
out.ExperimentalAllocatableIgnoreEviction = in.ExperimentalAllocatableIgnoreEviction
out.ShutdownGracePeriod = in.ShutdownGracePeriod
out.ShutdownGracePeriodCriticalPods = in.ShutdownGracePeriodCriticalPods
out.MemorySwapBehavior = in.MemorySwapBehavior

View File

@ -3914,6 +3914,11 @@ func (in *KubeletConfigSpec) DeepCopyInto(out *KubeletConfigSpec) {
*out = new(int64)
**out = **in
}
if in.ExperimentalAllocatableIgnoreEviction != nil {
in, out := &in.ExperimentalAllocatableIgnoreEviction, &out.ExperimentalAllocatableIgnoreEviction
*out = new(bool)
**out = **in
}
if in.ShutdownGracePeriod != nil {
in, out := &in.ShutdownGracePeriod, &out.ShutdownGracePeriod
*out = new(v1.Duration)

View File

@ -4093,6 +4093,11 @@ func (in *KubeletConfigSpec) DeepCopyInto(out *KubeletConfigSpec) {
*out = new(int64)
**out = **in
}
if in.ExperimentalAllocatableIgnoreEviction != nil {
in, out := &in.ExperimentalAllocatableIgnoreEviction, &out.ExperimentalAllocatableIgnoreEviction
*out = new(bool)
**out = **in
}
if in.ShutdownGracePeriod != nil {
in, out := &in.ShutdownGracePeriod, &out.ShutdownGracePeriod
*out = new(v1.Duration)