From: Anil Belur Date: Tue, 22 Oct 2019 14:42:31 +0000 (+0000) Subject: Merge "Add step to verify stage repo is closed" X-Git-Tag: v0.46.0~2 X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=commitdiff_plain;h=0ebc82e3022f7d92eaec14888d05114584a3c20c;hp=718fdb52ab8a23a16e91f80a7d8ae26d116ca6ea;p=releng%2Fglobal-jjb.git Merge "Add step to verify stage repo is closed" --- diff --git a/releasenotes/notes/verify-staging-repo-92ae65287c42d2d2.yaml b/releasenotes/notes/verify-staging-repo-92ae65287c42d2d2.yaml new file mode 100644 index 00000000..cc2a8bed --- /dev/null +++ b/releasenotes/notes/verify-staging-repo-92ae65287c42d2d2.yaml @@ -0,0 +1,7 @@ +--- +fixes: + - | + Add step to verify Nexus staging repository is closed correctly or + fail the staging job, if the repository is still open. This allows + projects to address the validation failures earlier during maven-stage + phase, instead of waiting to catch them while running the self-release job. diff --git a/shell/maven-stage.sh b/shell/maven-stage.sh index fa890475..63d3f1e4 100644 --- a/shell/maven-stage.sh +++ b/shell/maven-stage.sh @@ -22,6 +22,9 @@ TMP_FILE="$(mktemp)" lftools deploy nexus-stage "$NEXUS_URL" "$STAGING_PROFILE_ID" "$WORKSPACE/m2repo" | tee "$TMP_FILE" staging_repo=$(sed -n -e 's/Staging repository \(.*\) created\./\1/p' "$TMP_FILE") +echo "INFO: Verify Nexus staging repository is closed" +lftools nexus release -v --server "$NEXUS_URL" "$staging_repo" + # Store repo info to a file in archives mkdir -p "$WORKSPACE/archives" echo "$staging_repo ${NEXUS_URL}/content/repositories/$staging_repo" | tee -a "$WORKSPACE/archives/staging-repo.txt"