X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=blobdiff_plain;f=shell%2Frelease-job.sh;h=3a36a579bb25f7fa2398e43d75b8d66878cade01;hb=97b2c167fe54298814d5985f705ac767fd1912be;hp=6510ce5b26a1ff073772f7b9b1859893f9dc15b5;hpb=050cdffb159645926fdce4194acc180e9ff8a108;p=releng%2Fglobal-jjb.git diff --git a/shell/release-job.sh b/shell/release-job.sh index 6510ce5b..3a36a579 100644 --- a/shell/release-job.sh +++ b/shell/release-job.sh @@ -75,11 +75,17 @@ nexus_release(){ lftools nexus release -v --server https://"$NEXUS_URL" "$STAGING_REPO" echo "Merge will run" echo "lftools nexus release --server https://$NEXUS_URL $STAGING_REPO" - if [[ "$JOB_NAME" =~ "merge" ]]; then + done + #Run the loop twice, to catch errors on either nexus repo + + if [[ "$JOB_NAME" =~ "merge" ]]; then + for staging_url in $(zcat "$PATCH_DIR"/staging-repo.txt.gz | awk -e '{print $2}'); do + NEXUS_URL=$(echo "$staging_url" | sed -e 's|^[^/]*//||' -e 's|/.*$||') + STAGING_REPO=${staging_url#*repositories/} echo "Promoting $STAGING_REPO on $NEXUS_URL." lftools nexus release --server https://"$NEXUS_URL" "$STAGING_REPO" - fi - done + done + fi }