From 8176403426a25bbf60bb2d64b5bb77365fef78c8 Mon Sep 17 00:00:00 2001 From: Justin Cormack Date: Sat, 8 Apr 2017 16:56:47 +0100 Subject: [PATCH] =?UTF-8?q?system=20=E2=86=92=20onboot=20=20daemon=20?= =?UTF-8?q?=E2=86=92=20services?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit As suggested by @shykes these are clearer - onboot for things that are run at boot time to completion - services for persistent services Signed-off-by: Justin Cormack --- src/cmd/moby/build.go | 12 ++++++------ src/cmd/moby/config.go | 10 +++++----- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/cmd/moby/build.go b/src/cmd/moby/build.go index 2de9c146d..ed3d887f7 100644 --- a/src/cmd/moby/build.go +++ b/src/cmd/moby/build.go @@ -137,8 +137,8 @@ func buildInternal(name string, pull bool, conf string) { initrdAppend(iw, buffer) } - log.Infof("Add system containers:") - for i, image := range m.System { + log.Infof("Add onboot containers:") + for i, image := range m.Onboot { if pull || enforceContentTrust(image.Image, &m.Trust) { log.Infof(" Pull: %s", image.Image) err := dockerPull(image.Image, enforceContentTrust(image.Image, &m.Trust)) @@ -152,7 +152,7 @@ func buildInternal(name string, pull bool, conf string) { log.Fatalf("Failed to create config.json for %s: %v", image.Image, err) } so := fmt.Sprintf("%03d", i) - path := "containers/system/" + so + "-" + image.Name + path := "containers/onboot/" + so + "-" + image.Name out, err := ImageBundle(path, image.Image, config) if err != nil { log.Fatalf("Failed to extract root filesystem for %s: %v", image.Image, err) @@ -161,8 +161,8 @@ func buildInternal(name string, pull bool, conf string) { initrdAppend(iw, buffer) } - log.Infof("Add daemon containers:") - for _, image := range m.Daemon { + log.Infof("Add service containers:") + for _, image := range m.Services { if pull || enforceContentTrust(image.Image, &m.Trust) { log.Infof(" Pull: %s", image.Image) err := dockerPull(image.Image, enforceContentTrust(image.Image, &m.Trust)) @@ -175,7 +175,7 @@ func buildInternal(name string, pull bool, conf string) { if err != nil { log.Fatalf("Failed to create config.json for %s: %v", image.Image, err) } - path := "containers/daemon/" + image.Name + path := "containers/services/" + image.Name out, err := ImageBundle(path, image.Image, config) if err != nil { log.Fatalf("Failed to extract root filesystem for %s: %v", image.Image, err) diff --git a/src/cmd/moby/config.go b/src/cmd/moby/config.go index 9c93767df..11a9eafe4 100644 --- a/src/cmd/moby/config.go +++ b/src/cmd/moby/config.go @@ -24,11 +24,11 @@ type Moby struct { Image string Cmdline string } - Init []string - System []MobyImage - Daemon []MobyImage - Trust TrustConfig - Files []struct { + Init []string + Onboot []MobyImage + Services []MobyImage + Trust TrustConfig + Files []struct { Path string Directory bool Contents string