diff options
| author | Christine Dodrill <me@christine.website> | 2019-06-26 21:28:11 +0000 |
|---|---|---|
| committer | Christine Dodrill <me@christine.website> | 2019-06-26 21:28:11 +0000 |
| commit | 2a73e72c2f4bec8eb53120e8881655b56966b85f (patch) | |
| tree | 65d925142bc4a51a2039b5fb29e4e6fb8acd340b /docker.go | |
| parent | 153914d24f62312cdef8e52a5cf47866fa27b793 (diff) | |
| download | x-1.1.3.tar.xz x-1.1.3.zip | |
internal/yeet: fix DockerBuild, oopsv1.1.3
Diffstat (limited to 'docker.go')
| -rw-r--r-- | docker.go | 16 |
1 files changed, 12 insertions, 4 deletions
@@ -5,13 +5,19 @@ package main import ( "context" + "flag" "log" "path/filepath" "within.website/x/internal/yeet" ) +var ( + dontPush = flag.Bool("dont-push", false, "if set, don't push docker images") +) + func main() { + flag.Parse() ctx, cancel := context.WithCancel(context.Background()) defer cancel() @@ -35,10 +41,12 @@ func main() { yeet.DockerBuild(ctx, filepath.Join(yeet.WD, "cmd", "h"), hTag, "--build-arg", "X_VERSION="+gitTag) - yeet.ShouldWork(ctx, nil, yeet.WD, "docker", "push", resTag) - yeet.ShouldWork(ctx, nil, yeet.WD, "docker", "push", otherResTag) - yeet.ShouldWork(ctx, nil, yeet.WD, "docker", "push", dnsdGithubTag) - yeet.ShouldWork(ctx, nil, yeet.WD, "docker", "push", hTag) + if !*dontPush { + yeet.ShouldWork(ctx, nil, yeet.WD, "docker", "push", resTag) + yeet.ShouldWork(ctx, nil, yeet.WD, "docker", "push", otherResTag) + yeet.ShouldWork(ctx, nil, yeet.WD, "docker", "push", dnsdGithubTag) + yeet.ShouldWork(ctx, nil, yeet.WD, "docker", "push", hTag) + } log.Printf("xperimental:\t%s", otherResTag) log.Printf("dnsd:\t%s", dnsdGithubTag) |
