Add CNI support to ctr run

This adds linux cni support to `ctr run` via a `--cni` flag.  This uses the
default configuration for CNI on `ctr` to configure the network namespace for a
container.

Signed-off-by: Michael Crosby <michael@thepasture.io>
This commit is contained in:
Michael Crosby
2020-10-14 22:37:53 -04:00
parent 9b70de01d6
commit 21b6f68765
2 changed files with 42 additions and 4 deletions

View File

@@ -68,6 +68,10 @@ var platformRunFlags = []cli.Flag{
Usage: "set the CFS cpu quota",
Value: 0.0,
},
cli.BoolFlag{
Name: "cni",
Usage: "enable cni networking for the container",
},
}
// NewContainer creates a new container