Add logging to /var/log for onboot containers

Signed-off-by: Avi Deitcher <avi@deitcher.net>
This commit is contained in:
Avi Deitcher
2018-02-15 21:59:53 +02:00
parent 2a553dc644
commit cc57288b64
2 changed files with 70 additions and 7 deletions

View File

@@ -83,9 +83,9 @@ func main() {
command := os.Args[0]
switch {
case strings.Contains(command, "onboot"):
os.Exit(runcInit(onbootPath))
os.Exit(runcInit(onbootPath, "onboot"))
case strings.Contains(command, "onshutdown"):
os.Exit(runcInit(shutdownPath))
os.Exit(runcInit(shutdownPath, "shutdown"))
case strings.Contains(command, "containerd"):
systemInitCmd(ctx, []string{})
os.Exit(0)