Skip to content

Commit

Permalink
kubelet: reuse manager
Browse files Browse the repository at this point in the history
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
  • Loading branch information
giuseppe authored and kolyshkin committed May 20, 2021
1 parent e338438 commit dc12c60
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions pkg/kubelet/cm/container_manager_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -534,12 +534,8 @@ func (cm *containerManagerImpl) setupNode(activePods ActivePodsFunc) error {
return err
}

manager, err := createManager(cm.KubeletCgroupsName)
if err != nil {
return err
}
cont.ensureStateFunc = func(_ cgroups.Manager) error {
return ensureProcessInContainerWithOOMScore(os.Getpid(), qos.KubeletOOMScoreAdj, manager)
return ensureProcessInContainerWithOOMScore(os.Getpid(), qos.KubeletOOMScoreAdj, cont.manager)
}
systemContainers = append(systemContainers, cont)
} else {
Expand Down

0 comments on commit dc12c60

Please sign in to comment.