Skip to content
This repository has been archived by the owner on Aug 5, 2022. It is now read-only.

Commit

Permalink
add error handling pt 2
Browse files Browse the repository at this point in the history
  • Loading branch information
stephenlacy committed Mar 25, 2021
1 parent 2bb77b8 commit 68d9bd2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pkg/monokube/monokube.go
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ OUTER:

dockerTpl, err := parseTemplate(dockerArgs, pkg)
if err != nil {
color.Red("'--docker-args' has an invalid template")
exit("'--docker-args' has an invalid template")
}
pkg.DockerArgs = dockerTpl

Expand Down Expand Up @@ -244,7 +244,7 @@ OUTER:
color.Cyan("building image %s\n", pkg.Image)
err := runBackground(pkg, "bash", "-c", cmd)
if err != nil {
color.Red("error building image %s %e \n", pkg.Image, err.Error())
exit("error building image %s %e \n", pkg.Image, err.Error())
break
}

Expand All @@ -255,7 +255,7 @@ OUTER:
color.Cyan("pushing image: %s\n", pkg.Image)
err = runBackground(pkg, "docker", "push", pkg.Image)
if err != nil {
color.Red("error pushing image %s %e \n", pkg.Image, err.Error())
exit("error pushing image %s %e \n", pkg.Image, err.Error())
break
}
}
Expand Down

0 comments on commit 68d9bd2

Please sign in to comment.