--- a/ChangeLog Mon May 22 00:02:20 2017 -0500
+++ b/ChangeLog Tue May 30 20:45:02 2017 -0500
@@ -1,5 +1,6 @@
- * Nothing yet :( Be the first!!
+ * Added support for passing arguments to the Docker build task (--build-arg). * Added GIT_BRANCH_NORMALIZED and HG_BRANCH_NORMALIZED variables into the
--- a/docker/build.go Mon May 22 00:02:20 2017 -0500
+++ b/docker/build.go Tue May 30 20:45:02 2017 -0500
@@ -37,12 +37,14 @@
Files []string `yaml:"files"`
Labels []string `yaml:"labels"`
+ Arguments []string `yaml:"arguments"` const buildTemplate = `docker build
{{if .tag}} -t {{.tag}}{{end}}
{{range .Labels}} --label '{{.}}'{{end}}
+{{range .Arguments}} --build-arg {{.}}{{end}} func (b *Build) Execute(name string, ws *workspace.Workspace, logger *gomol.LogAdapter, env []string, st *state.State) error {
@@ -86,6 +88,7 @@
"tag": environment.Mapper(b.Tag, fullEnv),
+ "Arguments": b.Arguments, return command.Run(name, buildTemplate, params, st.TaskTimeout)