diff --git a/daemon/oci_linux.go b/daemon/oci_linux.go index 5a2158c222..91c0f5eded 100644 --- a/daemon/oci_linux.go +++ b/daemon/oci_linux.go @@ -593,7 +593,7 @@ func (daemon *Daemon) populateCommonSpec(s *specs.Spec, c *container.Container) if c.HostConfig.PidMode.IsPrivate() { if (c.HostConfig.Init != nil && *c.HostConfig.Init) || (c.HostConfig.Init == nil && daemon.configStore.Init) { - s.Process.Args = append([]string{"/dev/init", c.Path}, c.Args...) + s.Process.Args = append([]string{"/dev/init", "--", c.Path}, c.Args...) var path string if daemon.configStore.InitPath == "" && c.HostConfig.InitPath == "" { path, err = exec.LookPath(DefaultInitBinary) diff --git a/hack/dockerfile/install-binaries.sh b/hack/dockerfile/install-binaries.sh index bd4c63c645..7c1984b0d2 100755 --- a/hack/dockerfile/install-binaries.sh +++ b/hack/dockerfile/install-binaries.sh @@ -77,7 +77,7 @@ do git clone https://github.com/krallin/tini.git "$GOPATH/tini" cd "$GOPATH/tini" git checkout -q "$TINI_COMMIT" - cmake -DMINIMAL=ON . + cmake . make tini-static cp tini-static /usr/local/bin/docker-init ;;