mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-15 22:20:51 +00:00
Exclude critical pods from having swap access
Signed-off-by: Itamar Holder <iholder@redhat.com>
This commit is contained in:
@@ -180,6 +180,11 @@ func (m *kubeGenericRuntimeManager) configureContainerSwapResources(lcr *runtime
|
||||
return
|
||||
}
|
||||
|
||||
if kubelettypes.IsCriticalPod(pod) {
|
||||
swapConfigurationHelper.ConfigureNoSwap(lcr)
|
||||
return
|
||||
}
|
||||
|
||||
// NOTE(ehashman): Behavior is defined in the opencontainers runtime spec:
|
||||
// https://github.com/opencontainers/runtime-spec/blob/1c3f411f041711bbeecf35ff7e93461ea6789220/config-linux.md#memory
|
||||
switch m.memorySwapBehavior {
|
||||
|
Reference in New Issue
Block a user