1
0
mirror of https://github.com/rancher/os.git synced 2025-09-03 15:54:24 +00:00

Show current/enabled/disabled in 'ros engine list'

This commit is contained in:
Josh Curl
2016-08-17 16:33:49 -07:00
parent a81be13f82
commit 11cf2a195b
6 changed files with 45 additions and 2 deletions

View File

@@ -10,12 +10,14 @@ import (
"time"
log "github.com/Sirupsen/logrus"
"github.com/rancher/os/config"
"github.com/rancher/os/util"
)
const (
consoleDone = "/run/console-done"
dockerConf = "/var/lib/rancher/conf/docker"
dockerDone = "/run/docker-done"
dockerLog = "/var/log/docker.log"
)
@@ -80,6 +82,12 @@ func Main() {
args = append(args, os.Getenv("DOCKER_OPTS"))
}
cfg := config.LoadConfig()
if err := ioutil.WriteFile(dockerDone, []byte(cfg.Rancher.Docker.Engine), 0644); err != nil {
log.Error(err)
}
log.Fatal(syscall.Exec("/usr/bin/dockerlaunch", args, os.Environ()))
}