diff --git a/flags.go b/flags.go index a8ca71916a..4c7da485a3 100644 --- a/flags.go +++ b/flags.go @@ -98,9 +98,10 @@ var ( Usage: "filter to use [" + strings.Join(filter.List(), ", ") + "]", Value: &flFilterValue, } - flCluster = cli.StringFlag{ - Name: "cluster, c", - Usage: "cluster to use [swarm, mesos]", - Value: "swarm", - } + +// flCluster = cli.StringFlag{ +// Name: "cluster, c", +// Usage: "cluster to use [swarm, mesos]", +// Value: "swarm", +// } ) diff --git a/main.go b/main.go index 1107ff9394..15e1de93f6 100644 --- a/main.go +++ b/main.go @@ -105,7 +105,7 @@ func main() { ShortName: "m", Usage: "manage a docker cluster", Flags: []cli.Flag{ - flStore, flCluster, + flStore, flStrategy, flFilter, flHosts, flHeartBeat, flOverCommit, flTLS, flTLSCaCert, flTLSCert, flTLSKey, flTLSVerify, diff --git a/scheduler/filter/filter.go b/scheduler/filter/filter.go index 46dd8890ae..36bd3074ac 100644 --- a/scheduler/filter/filter.go +++ b/scheduler/filter/filter.go @@ -66,6 +66,7 @@ func ApplyFilters(filters []Filter, config *dockerclient.ContainerConfig, nodes return nodes, nil } +// List returns the names of all the available filters func List() []string { names := []string{} diff --git a/scheduler/strategy/strategy.go b/scheduler/strategy/strategy.go index 61493e69a6..93afcd075c 100644 --- a/scheduler/strategy/strategy.go +++ b/scheduler/strategy/strategy.go @@ -36,7 +36,7 @@ func init() { // New is exported func New(name string) (PlacementStrategy, error) { - if name == "binpacking" { //compat + if name == "binpacking" { //TODO: remove this compat name = "binpack" } @@ -51,6 +51,7 @@ func New(name string) (PlacementStrategy, error) { return nil, ErrNotSupported } +// List returns the names of all the available strategies func List() []string { names := []string{}