Skip to content

Commit c3843eb

Browse files
arschlesAaron Schlesinger
authored andcommitted
fix(build.go): bail on error to launch build pod
1 parent eec45e8 commit c3843eb

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

pkg/gitreceive/build.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -353,6 +353,8 @@ func build(conf *Config, builderKey, gitSha string) error {
353353
}
354354
if strings.Contains(string(out.Bytes()), "phase: Running") {
355355
break
356+
} else if strings.Contains(outStr, "phase: Failed") {
357+
return fmt.Errorf("build pod %s entered phase: Failed", buildPodName)
356358
}
357359
time.Sleep(100 * time.Millisecond)
358360
}

0 commit comments

Comments
 (0)