mirror of
https://github.com/optim-enterprises-bv/kubernetes.git
synced 2025-11-01 18:58:18 +00:00
Set MemorySwapLimitInBytes for CRI when NodeSwapEnabled
This commit is contained in:
@@ -144,6 +144,9 @@ type kubeGenericRuntimeManager struct {
|
||||
|
||||
// Use RuntimeDefault as the default seccomp profile for all workloads.
|
||||
seccompDefault bool
|
||||
|
||||
// MemorySwapBehavior defines how swap is used
|
||||
memorySwapBehavior string
|
||||
}
|
||||
|
||||
// KubeGenericRuntime is a interface contains interfaces for container runtime and command.
|
||||
@@ -186,6 +189,7 @@ func NewKubeGenericRuntimeManager(
|
||||
logManager logs.ContainerLogManager,
|
||||
runtimeClassManager *runtimeclass.Manager,
|
||||
seccompDefault bool,
|
||||
memorySwapBehavior string,
|
||||
) (KubeGenericRuntime, error) {
|
||||
kubeRuntimeManager := &kubeGenericRuntimeManager{
|
||||
recorder: recorder,
|
||||
@@ -206,6 +210,7 @@ func NewKubeGenericRuntimeManager(
|
||||
runtimeClassManager: runtimeClassManager,
|
||||
logReduction: logreduction.NewLogReduction(identicalErrorDelay),
|
||||
seccompDefault: seccompDefault,
|
||||
memorySwapBehavior: memorySwapBehavior,
|
||||
}
|
||||
|
||||
typedVersion, err := kubeRuntimeManager.getTypedVersion()
|
||||
|
||||
Reference in New Issue
Block a user