From 23484e4821ea6a0f80998c1250c5db40d7863b4b Mon Sep 17 00:00:00 2001 From: Darren Shepherd Date: Thu, 19 Feb 2015 08:34:38 -0700 Subject: [PATCH] Default config changes --- config/config.go | 11 ++++------- config/default.go | 5 +++-- 2 files changed, 7 insertions(+), 9 deletions(-) diff --git a/config/config.go b/config/config.go index 189f022c..6307fe73 100644 --- a/config/config.go +++ b/config/config.go @@ -27,21 +27,18 @@ const ( ) var ( - ConfigFile = "/var/lib/rancher/rancher.yml" + ConfigFile = "/var/lib/rancher/conf/rancher.yml" ) type InitFunc func(*Config) error type ContainerConfig struct { - Id string `yaml:"id,omitempty"` - Cmd string `yaml:"run,omitempty"` - //Config *runconfig.Config `yaml:"-"` - //HostConfig *runconfig.HostConfig `yaml:"-"` + Id string `yaml:"id,omitempty"` + Cmd string `yaml:"run,omitempty"` + MigrateVolumes bool `yaml:"migrate_volumes,omitempty"` } type Config struct { - //BootstrapContainers []ContainerConfig `yaml:"bootstrapContainers,omitempty"` - //UserContainers []ContainerConfig `yaml:"userContainser,omitempty"` Debug bool `yaml:"debug,omitempty"` Disable []string `yaml:"disable,omitempty"` Dns []string `yaml:"dns,flow,omitempty"` diff --git a/config/default.go b/config/default.go index 272df1e6..8bd24695 100644 --- a/config/default.go +++ b/config/default.go @@ -12,14 +12,14 @@ func NewConfig() *Config { Dev: "LABEL=RANCHER_STATE", FsType: "auto", }, - SystemDockerArgs: []string{"docker", "-d", "-s", "overlay", "-b", "none"}, + SystemDockerArgs: []string{"docker", "-d", "-s", "overlay", "-b", "none", "--restart=false"}, Modules: []string{}, SystemContainers: []ContainerConfig{ { Cmd: "--name=system-state " + "--net=none " + "--read-only " + - "-v=/var/lib/rancher/etc:/var/lib/rancher/etc " + + "-v=/var/lib/rancher/conf:/var/lib/rancher/conf " + "state", }, { @@ -72,6 +72,7 @@ func NewConfig() *Config { }, { Cmd: "--name=ntp " + + "--rm " + "-d " + "--privileged " + "--net=host " +