diff --git a/tools/container/containerd/config.go b/tools/container/containerd/config.go index 629ec7f3..2e61be5d 100644 --- a/tools/container/containerd/config.go +++ b/tools/container/containerd/config.go @@ -48,6 +48,9 @@ func (config *config) update(runtimeClass string, runtimeType string, runtimeBin } config.initRuntime(runtimeClassPath, runtimeType, "BinaryName", runtimeBinary) + if config.version == 1 { + config.initRuntime(runtimeClassPath, runtimeType, "Runtime", runtimeBinary) + } if setAsDefault { defaultRuntimeNamePath := config.defaultRuntimeNamePath() diff --git a/tools/container/containerd/config_v1_test.go b/tools/container/containerd/config_v1_test.go index b1f39677..0b69f5aa 100644 --- a/tools/container/containerd/config_v1_test.go +++ b/tools/container/containerd/config_v1_test.go @@ -349,6 +349,7 @@ func runtimeMapV1(binary string) map[string]interface{} { "privileged_without_host_devices": false, "options": map[string]interface{}{ "BinaryName": binary, + "Runtime": binary, }, } } @@ -376,6 +377,7 @@ func runcRuntimeConfigMapV1(binary string) map[string]interface{} { "options": map[string]interface{}{ "runc-option": "value", "BinaryName": binary, + "Runtime": binary, }, } }