Revert "Restore "containerd: upgrade io.containerd.runtime.v1.linux to io.containerd.runc.v2 (suppot cgroup v2)""
parent
13be173ec8
commit
e37f4e4014
|
@ -49,6 +49,7 @@ const (
|
||||||
containerdConfigTemplate = `root = "/var/lib/containerd"
|
containerdConfigTemplate = `root = "/var/lib/containerd"
|
||||||
state = "/run/containerd"
|
state = "/run/containerd"
|
||||||
oom_score = 0
|
oom_score = 0
|
||||||
|
|
||||||
[grpc]
|
[grpc]
|
||||||
address = "/run/containerd/containerd.sock"
|
address = "/run/containerd/containerd.sock"
|
||||||
uid = 0
|
uid = 0
|
||||||
|
@ -78,21 +79,16 @@ oom_score = 0
|
||||||
enable_selinux = false
|
enable_selinux = false
|
||||||
sandbox_image = "{{ .PodInfraContainerImage }}"
|
sandbox_image = "{{ .PodInfraContainerImage }}"
|
||||||
stats_collect_period = 10
|
stats_collect_period = 10
|
||||||
|
systemd_cgroup = {{ .SystemdCgroup }}
|
||||||
enable_tls_streaming = false
|
enable_tls_streaming = false
|
||||||
max_container_log_line_size = 16384
|
max_container_log_line_size = 16384
|
||||||
|
|
||||||
[plugins."io.containerd.grpc.v1.cri"]
|
|
||||||
[plugins."io.containerd.grpc.v1.cri".containerd]
|
|
||||||
[plugins."io.containerd.grpc.v1.cri".containerd.runtimes]
|
|
||||||
[plugins."io.containerd.grpc.v1.cri".containerd.runtimes.runc]
|
|
||||||
runtime_type = "io.containerd.runc.v2"
|
|
||||||
[plugins."io.containerd.grpc.v1.cri".containerd.runtimes.runc.options]
|
|
||||||
SystemdCgroup = {{ .SystemdCgroup }}
|
|
||||||
|
|
||||||
[plugins.cri.containerd]
|
[plugins.cri.containerd]
|
||||||
snapshotter = "overlayfs"
|
snapshotter = "overlayfs"
|
||||||
|
no_pivot = true
|
||||||
[plugins.cri.containerd.default_runtime]
|
[plugins.cri.containerd.default_runtime]
|
||||||
runtime_type = "io.containerd.runc.v2"
|
runtime_type = "io.containerd.runtime.v1.linux"
|
||||||
|
runtime_engine = ""
|
||||||
|
runtime_root = ""
|
||||||
[plugins.cri.containerd.untrusted_workload_runtime]
|
[plugins.cri.containerd.untrusted_workload_runtime]
|
||||||
runtime_type = ""
|
runtime_type = ""
|
||||||
runtime_engine = ""
|
runtime_engine = ""
|
||||||
|
@ -111,6 +107,12 @@ oom_score = 0
|
||||||
{{ end -}}
|
{{ end -}}
|
||||||
[plugins.diff-service]
|
[plugins.diff-service]
|
||||||
default = ["walking"]
|
default = ["walking"]
|
||||||
|
[plugins.linux]
|
||||||
|
shim = "containerd-shim"
|
||||||
|
runtime = "runc"
|
||||||
|
runtime_root = ""
|
||||||
|
no_shim = false
|
||||||
|
shim_debug = false
|
||||||
[plugins.scheduler]
|
[plugins.scheduler]
|
||||||
pause_threshold = 0.02
|
pause_threshold = 0.02
|
||||||
deletion_threshold = 0
|
deletion_threshold = 0
|
||||||
|
|
|
@ -114,7 +114,7 @@ func validateContainerdSystemd(ctx context.Context, t *testing.T, profile string
|
||||||
if err != nil {
|
if err != nil {
|
||||||
t.Errorf("failed to get docker cgroup driver. args %q: %v", rr.Command(), err)
|
t.Errorf("failed to get docker cgroup driver. args %q: %v", rr.Command(), err)
|
||||||
}
|
}
|
||||||
if !strings.Contains(rr.Output(), "SystemdCgroup = true") {
|
if !strings.Contains(rr.Output(), "systemd_cgroup = true") {
|
||||||
t.Fatalf("expected systemd cgroup driver, got: %v", rr.Output())
|
t.Fatalf("expected systemd cgroup driver, got: %v", rr.Output())
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -65,7 +65,7 @@ func TestInsufficientStorage(t *testing.T) {
|
||||||
verifyClusterState(t, stdout)
|
verifyClusterState(t, stdout)
|
||||||
}
|
}
|
||||||
|
|
||||||
// runStatusCmd runs the status command expecting non-zero exit code and returns stdout
|
// runStatusCmd runs the status command and returns stdout
|
||||||
func runStatusCmd(ctx context.Context, t *testing.T, profile string, increaseEnv bool) []byte {
|
func runStatusCmd(ctx context.Context, t *testing.T, profile string, increaseEnv bool) []byte {
|
||||||
// make sure minikube status shows insufficient storage
|
// make sure minikube status shows insufficient storage
|
||||||
c := exec.CommandContext(ctx, Target(), "status", "-p", profile, "--output=json", "--layout=cluster")
|
c := exec.CommandContext(ctx, Target(), "status", "-p", profile, "--output=json", "--layout=cluster")
|
||||||
|
@ -76,7 +76,7 @@ func runStatusCmd(ctx context.Context, t *testing.T, profile string, increaseEnv
|
||||||
rr, err := Run(t, c)
|
rr, err := Run(t, c)
|
||||||
// status exits non-0 if status isn't Running
|
// status exits non-0 if status isn't Running
|
||||||
if err == nil {
|
if err == nil {
|
||||||
t.Fatalf("expected command to fail, but it succeeded: %v", rr.Command())
|
t.Fatalf("expected command to fail, but it succeeded: %v\n%v", rr.Command(), err)
|
||||||
}
|
}
|
||||||
return rr.Stdout.Bytes()
|
return rr.Stdout.Bytes()
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue