Made the image name a shared const.

This commit is contained in:
Travis Reeder
2017-05-23 13:11:50 -07:00
parent e71c3be9cf
commit f294b65587
3 changed files with 6 additions and 2 deletions

View File

@@ -14,6 +14,10 @@ import (
"gitlab.oracledx.com/odx/functions/fn/langs"
)
const (
functionsDockerImage = "treeder/functions"
)
func verbwriter(verbose bool) io.Writer {
// this is too limiting, removes all logs which isn't what we want
// verbwriter := ioutil.Discard

View File

@@ -44,7 +44,7 @@ func start(c *cli.Context) error {
for _, v := range denvs {
args = append(args, "-e", v)
}
args = append(args, "treeder/functions")
args = append(args, functionsDockerImage)
cmd := exec.Command("docker", args...)
cmd.Stdout = os.Stdout
cmd.Stderr = os.Stderr

View File

@@ -20,7 +20,7 @@ func updateCmd() cli.Command {
func update(c *cli.Context) error {
args := []string{"pull",
"treeder/functions:latest",
functionsDockerImage,
}
cmd := exec.Command("docker", args...)
cmd.Stdout = os.Stdout