mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-11 21:12:07 +00:00
Explicitly set LimitedSwap case with fallthrough
This commit is contained in:
parent
39f32d7286
commit
5584725605
@ -97,6 +97,8 @@ func (m *kubeGenericRuntimeManager) generateLinuxContainerConfig(container *v1.C
|
|||||||
case kubelettypes.UnlimitedSwap:
|
case kubelettypes.UnlimitedSwap:
|
||||||
// -1 = unlimited swap
|
// -1 = unlimited swap
|
||||||
lc.Resources.MemorySwapLimitInBytes = -1
|
lc.Resources.MemorySwapLimitInBytes = -1
|
||||||
|
case kubelettypes.LimitedSwap:
|
||||||
|
fallthrough
|
||||||
default:
|
default:
|
||||||
// memorySwapLimit = total permitted memory+swap; if equal to memory limit, => 0 swap above memory limit
|
// memorySwapLimit = total permitted memory+swap; if equal to memory limit, => 0 swap above memory limit
|
||||||
// Some swapping is still possible.
|
// Some swapping is still possible.
|
||||||
|
Loading…
Reference in New Issue
Block a user