Skip to content
This repository has been archived by the owner on Jan 13, 2025. It is now read-only.

Commit

Permalink
Update OpenShiftBuildHelper.groovy
Browse files Browse the repository at this point in the history
  • Loading branch information
cvarjao committed Jul 12, 2019
1 parent 53abed6 commit aa81272
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/main/groovy/ca/bc/gov/devops/OpenShiftBuildHelper.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -533,8 +533,10 @@ class OpenShiftBuildHelper extends OpenShiftHelper{
if ('Waiting' == item.phase) continue

if (item['build-name']){
if (!waitForPodsToComplete(['pods', '-l', "openshift.io/build.name=${item['build-name'].substring(6)}", "--namespace=${config.app.build.namespace}"])){
throw new RuntimeException("One or more build(s) did NOT complete successfully")
String shortBuildName = item['build-name'].tokenize('/')[1]

if (!waitForPodsToComplete(['pods', '-l', "openshift.io/build.name=${shortBuildName}", "--namespace=${config.app.build.namespace}"])){
throw new RuntimeException("'${shortBuildName}' did NOT complete successfully")
}
//only wait for 1 build/pod to complete at the time
break
Expand Down

0 comments on commit aa81272

Please sign in to comment.