Shrink k3s wrapper binary

pull/1033/head
Darren Shepherd 2019-11-08 20:56:41 +00:00
parent 91cacb3a14
commit 53d3ab074c
1 changed files with 4 additions and 5 deletions

View File

@ -3,7 +3,6 @@ package cmds
import ( import (
"fmt" "fmt"
"github.com/rancher/k3s/pkg/daemons/config"
"github.com/urfave/cli" "github.com/urfave/cli"
) )
@ -114,9 +113,9 @@ func NewServerCommand(action func(*cli.Context) error) cli.Command {
}, },
cli.StringFlag{ cli.StringFlag{
Name: "flannel-backend", Name: "flannel-backend",
Usage: fmt.Sprintf("(networking) One of '%s', '%s', '%s', or '%s'", config.FlannelBackendNone, config.FlannelBackendVXLAN, config.FlannelBackendIPSEC, config.FlannelBackendWireguard), Usage: fmt.Sprintf("(networking) One of 'none', 'vxlan', 'ipsec', or 'flannel'"),
Destination: &ServerConfig.FlannelBackend, Destination: &ServerConfig.FlannelBackend,
Value: config.FlannelBackendVXLAN, Value: "vxlan",
}, },
cli.StringFlag{ cli.StringFlag{
Name: "token,t", Name: "token,t",
@ -149,14 +148,14 @@ func NewServerCommand(action func(*cli.Context) error) cli.Command {
Destination: &ServerConfig.ServerURL, Destination: &ServerConfig.ServerURL,
}, },
cli.BoolFlag{ cli.BoolFlag{
Name: "new-cluster", Name: "cluster-init",
Hidden: hideDqlite, Hidden: hideDqlite,
Usage: "(cluster) Initialize new cluster master", Usage: "(cluster) Initialize new cluster master",
EnvVar: "K3S_CLUSTER_INIT", EnvVar: "K3S_CLUSTER_INIT",
Destination: &ServerConfig.ClusterInit, Destination: &ServerConfig.ClusterInit,
}, },
cli.BoolFlag{ cli.BoolFlag{
Name: "reset-cluster", Name: "cluster-reset",
Hidden: hideDqlite, Hidden: hideDqlite,
Usage: "(cluster) Forget all peers and become a single cluster new cluster master", Usage: "(cluster) Forget all peers and become a single cluster new cluster master",
EnvVar: "K3S_CLUSTER_RESET", EnvVar: "K3S_CLUSTER_RESET",