Skip to content
This repository was archived by the owner on Dec 17, 2021. It is now read-only.

Commit f29d5ef

Browse files
committed
commands/create: Remove cli flags for swarm and SwarmOptions
1 parent 8a87809 commit f29d5ef

File tree

1 file changed

+0
-62
lines changed

1 file changed

+0
-62
lines changed

commands/create.go

Lines changed: 0 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ import (
2525
"github.com/docker/machine/libmachine/log"
2626
"github.com/docker/machine/libmachine/mcnerror"
2727
"github.com/docker/machine/libmachine/mcnflag"
28-
"github.com/docker/machine/libmachine/swarm"
2928
"github.com/lambda-linux/lambda-machine-local/commands/mcndirs"
3029
)
3130

@@ -77,54 +76,6 @@ var (
7776
Usage: "Specify environment variables to set in the engine",
7877
Value: &cli.StringSlice{},
7978
},
80-
cli.BoolFlag{
81-
Name: "swarm",
82-
Usage: "Configure Machine to join a Swarm cluster",
83-
},
84-
cli.StringFlag{
85-
Name: "swarm-image",
86-
Usage: "Specify Docker image to use for Swarm",
87-
Value: "swarm:latest",
88-
EnvVar: "MACHINE_SWARM_IMAGE",
89-
},
90-
cli.BoolFlag{
91-
Name: "swarm-master",
92-
Usage: "Configure Machine to be a Swarm master",
93-
},
94-
cli.StringFlag{
95-
Name: "swarm-discovery",
96-
Usage: "Discovery service to use with Swarm",
97-
Value: "",
98-
},
99-
cli.StringFlag{
100-
Name: "swarm-strategy",
101-
Usage: "Define a default scheduling strategy for Swarm",
102-
Value: "spread",
103-
},
104-
cli.StringSliceFlag{
105-
Name: "swarm-opt",
106-
Usage: "Define arbitrary flags for Swarm master",
107-
Value: &cli.StringSlice{},
108-
},
109-
cli.StringSliceFlag{
110-
Name: "swarm-join-opt",
111-
Usage: "Define arbitrary flags for Swarm join",
112-
Value: &cli.StringSlice{},
113-
},
114-
cli.StringFlag{
115-
Name: "swarm-host",
116-
Usage: "ip/socket to listen on for Swarm master",
117-
Value: "tcp://0.0.0.0:3376",
118-
},
119-
cli.StringFlag{
120-
Name: "swarm-addr",
121-
Usage: "addr to advertise for Swarm (default: detect and use the machine IP)",
122-
Value: "",
123-
},
124-
cli.BoolFlag{
125-
Name: "swarm-experimental",
126-
Usage: "Enable Swarm experimental features",
127-
},
12879
cli.StringSliceFlag{
12980
Name: "tls-san",
13081
Usage: "Support extra SANs for TLS certs",
@@ -190,19 +141,6 @@ func cmdCreateInner(c CommandLine, api libmachine.API) error {
190141
TLSVerify: true,
191142
InstallURL: c.String("engine-install-url"),
192143
},
193-
SwarmOptions: &swarm.Options{
194-
IsSwarm: c.Bool("swarm") || c.Bool("swarm-master"),
195-
Image: c.String("swarm-image"),
196-
Agent: c.Bool("swarm"),
197-
Master: c.Bool("swarm-master"),
198-
Discovery: c.String("swarm-discovery"),
199-
Address: c.String("swarm-addr"),
200-
Host: c.String("swarm-host"),
201-
Strategy: c.String("swarm-strategy"),
202-
ArbitraryFlags: c.StringSlice("swarm-opt"),
203-
ArbitraryJoinFlags: c.StringSlice("swarm-join-opt"),
204-
IsExperimental: c.Bool("swarm-experimental"),
205-
},
206144
}
207145

208146
exists, err := api.Exists(h.Name)

0 commit comments

Comments
 (0)