Merge pull request #43878 from thaJeztah/22.06_backport_containerd_config_v2

[22.06 backport] libcontainerd: switch generated containerd.toml to v2 (v1 is deprecated)
This commit is contained in:
Sebastiaan van Stijn 2022-07-28 21:19:38 +02:00 committed by GitHub
commit d8f20bfdc1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 3 deletions

View file

@ -608,7 +608,7 @@ func (cli *DaemonCli) getContainerdDaemonOpts() ([]supervisor.DaemonOpt, error)
}
if !cli.Config.CriContainerd {
opts = append(opts, supervisor.WithPlugin("cri", nil))
opts = append(opts, supervisor.WithPlugin("io.containerd.grpc.v1.cri", nil))
}
return opts, nil

View file

@ -62,8 +62,9 @@ func Start(ctx context.Context, rootDir, stateDir string, opts ...DaemonOpt) (Da
rootDir: rootDir,
stateDir: stateDir,
Config: config.Config{
Root: filepath.Join(rootDir, "daemon"),
State: filepath.Join(stateDir, "daemon"),
Version: 2,
Root: filepath.Join(rootDir, "daemon"),
State: filepath.Join(stateDir, "daemon"),
},
Plugins: make(map[string]interface{}),
daemonPid: -1,