Unverified Commit aab7045b authored by Erik Wilson's avatar Erik Wilson Committed by GitHub

Merge pull request #632 from ibuildthecloud/k3v

Add option to disable scheduler
parents ba4d920f dbb7b04c
...@@ -31,6 +31,7 @@ type Server struct { ...@@ -31,6 +31,7 @@ type Server struct {
StorageKeyFile string StorageKeyFile string
AdvertiseIP string AdvertiseIP string
AdvertisePort int AdvertisePort int
DisableScheduler bool
} }
var ServerConfig Server var ServerConfig Server
...@@ -191,6 +192,11 @@ func NewServerCommand(action func(*cli.Context) error) cli.Command { ...@@ -191,6 +192,11 @@ func NewServerCommand(action func(*cli.Context) error) cli.Command {
Value: 0, Value: 0,
Destination: &ServerConfig.AdvertisePort, Destination: &ServerConfig.AdvertisePort,
}, },
cli.BoolFlag{
Name: "disable-scheduler",
Usage: "Disable Kubernetes default scheduler",
Destination: &ServerConfig.DisableScheduler,
},
NodeIPFlag, NodeIPFlag,
NodeNameFlag, NodeNameFlag,
DockerFlag, DockerFlag,
......
...@@ -100,6 +100,7 @@ func run(app *cli.Context, cfg *cmds.Server) error { ...@@ -100,6 +100,7 @@ func run(app *cli.Context, cfg *cmds.Server) error {
serverConfig.ControlConfig.DataDir = cfg.DataDir serverConfig.ControlConfig.DataDir = cfg.DataDir
serverConfig.ControlConfig.KubeConfigOutput = cfg.KubeConfigOutput serverConfig.ControlConfig.KubeConfigOutput = cfg.KubeConfigOutput
serverConfig.ControlConfig.KubeConfigMode = cfg.KubeConfigMode serverConfig.ControlConfig.KubeConfigMode = cfg.KubeConfigMode
serverConfig.ControlConfig.NoScheduler = cfg.DisableScheduler
serverConfig.Rootless = cfg.Rootless serverConfig.Rootless = cfg.Rootless
serverConfig.TLSConfig.HTTPSPort = cfg.HTTPSPort serverConfig.TLSConfig.HTTPSPort = cfg.HTTPSPort
serverConfig.TLSConfig.HTTPPort = cfg.HTTPPort serverConfig.TLSConfig.HTTPPort = cfg.HTTPPort
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment