0
0
mirror of https://github.com/thegeeklab/wp-docker-buildx.git synced 2024-11-22 10:10:39 +00:00

Add support of --experimental flag

This commit is contained in:
Kévin Darcel 2017-01-19 12:17:43 -06:00
parent 37baf5e0d0
commit f55d828a22
No known key found for this signature in database
GPG Key ID: F29F49C57EA3F7AD
2 changed files with 10 additions and 0 deletions

View File

@ -75,6 +75,11 @@ func main() {
Usage: "docker daemon IPv6 networking",
EnvVar: "PLUGIN_IPV6",
},
cli.BoolFlag{
Name: "daemon.experimental",
Usage: "docker daemon Experimental mode",
EnvVar: "PLUGIN_EXPERIMENTAL",
},
cli.BoolFlag{
Name: "daemon.debug",
Usage: "docker daemon executes in debug mode",
@ -170,6 +175,7 @@ func run(c *cli.Context) error {
Bip: c.String("daemon.bip"),
DNS: c.StringSlice("daemon.dns"),
MTU: c.String("daemon.mtu"),
Experimental: c.Bool("daemon.experimental"),
},
}

View File

@ -28,6 +28,7 @@ type (
DNS []string // Docker daemon dns server
MTU string // Docker daemon mtu setting
IPv6 bool // Docker daemon IPv6 networking
Experimental bool // Docker daemon enable experimental mode
}
// Login defines Docker login parameters.
@ -276,6 +277,9 @@ func commandDaemon(daemon Daemon) *exec.Cmd {
if len(daemon.MTU) != 0 {
args = append(args, "--mtu", daemon.MTU)
}
if daemon.Experimental {
args = append(args, "--experimental")
}
return exec.Command(dockerExe, args...)
}