fix ctr tasks kill
does not remove cni network under windows
Signed-off-by: Iceber Gu <wei.cai-nat@daocloud.io>
This commit is contained in:
parent
6c8c427166
commit
a2df12d1a3
@ -131,6 +131,8 @@ func NewContainer(ctx gocontext.Context, client *containerd.Client, context *cli
|
|||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
opts = append(opts, oci.WithWindowsNetworkNamespace(ns.GetPath()))
|
opts = append(opts, oci.WithWindowsNetworkNamespace(ns.GetPath()))
|
||||||
|
cniMeta := &commands.NetworkMetaData{EnableCni: true}
|
||||||
|
cOpts = append(cOpts, containerd.WithContainerExtension(commands.CtrCniMetadataExtension, cniMeta))
|
||||||
}
|
}
|
||||||
if context.Bool("isolated") {
|
if context.Bool("isolated") {
|
||||||
opts = append(opts, oci.WithWindowsHyperV)
|
opts = append(opts, oci.WithWindowsHyperV)
|
||||||
|
Loading…
Reference in New Issue
Block a user