From 2718a5ed62a1b21a106c9a69742d6b763d092935 Mon Sep 17 00:00:00 2001 From: Adrien Delorme Date: Thu, 13 Dec 2018 10:23:46 +0100 Subject: [PATCH 1/2] Revert "revert changes to docker entrypoint; since this is a backwards-breaking change it needs to wait for a minor release" This reverts commit 2a79d64ae08e9d3400488c0c01813450d134feec. --- builder/docker/config.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builder/docker/config.go b/builder/docker/config.go index 6116a995b..ef2d52a63 100644 --- a/builder/docker/config.go +++ b/builder/docker/config.go @@ -73,7 +73,7 @@ func NewConfig(raws ...interface{}) (*Config, []string, error) { // Defaults if len(c.RunCommand) == 0 { - c.RunCommand = []string{"-d", "-i", "-t", "{{.Image}}", "/bin/bash"} + c.RunCommand = []string{"-d", "-i", "-t", "--entrypoint=/bin/sh", "--", "{{.Image}}"} } // Default Pull if it wasn't set From 20029f0a12b21f7aa97d6fce650d67019a7e19e7 Mon Sep 17 00:00:00 2001 From: Adrien Delorme Date: Thu, 13 Dec 2018 10:25:20 +0100 Subject: [PATCH 2/2] Also update docs --- website/source/docs/builders/docker.html.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/source/docs/builders/docker.html.md b/website/source/docs/builders/docker.html.md index 2193aa7e0..8d27e4493 100644 --- a/website/source/docs/builders/docker.html.md +++ b/website/source/docs/builders/docker.html.md @@ -210,7 +210,7 @@ You must specify (only) one of `commit`, `discard`, or `export_path`. - `run_command` (array of strings) - An array of arguments to pass to `docker run` in order to run the container. By default this is set to - `["-d", "-i", "-t", "{{.Image}}", "/bin/bash"]`. As you can see, you have a + `["-d", "-i", "-t", "{{.Image}}", "/bin/sh"]`. As you can see, you have a couple template variables to customize, as well. - `volumes` (map of strings to strings) - A mapping of additional volumes to