Update kubeadm_config.go

update the way to get containerd cgroup driver config
This commit is contained in:
littleBlackHouse 2023-05-30 17:56:19 +08:00 committed by GitHub
parent 32373dc0be
commit 64ceba3ae9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -383,7 +383,7 @@ func GetKubeletCgroupDriver(runtime connector.Runtime, kubeConf *common.KubeConf
case common.Crio:
cmd = "crio config | grep cgroup_manager"
case common.Conatinerd:
cmd = "containerd config dump | grep -i systemd |grep -i cgroup"
cmd = "containerd config dump | grep -i systemd |grep -i cgroup || echo 'SystemdCgroup = false'"
case common.Isula:
cmd = "isula info | grep 'Cgroup Driver'"
default: