Skip to content

Commit

Permalink
fix: add error handling for sig release creation during vhd automation (
Browse files Browse the repository at this point in the history
#5012)

Co-authored-by: Lily Pan <[email protected]>
  • Loading branch information
lilypan26 and Lily Pan authored Sep 30, 2024
1 parent a83eb80 commit 022487d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions vhdbuilder/scripts/automate_release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,10 @@ create_release() {
RESPONSE=$(curl -X POST -H "Authorization: Basic $(echo -n ":$ADO_PAT" | base64)" -H "Content-Type: application/json" -d "$REQUEST_BODY" "$RELEASE_API_ENDPOINT")

RELEASE_ID=$(echo "$RESPONSE" | jq -r '.id')
if [ -z "$RELEASE_ID" ]; then
echo "Error: SIG release not created successfully, unable to extract release ID"
return 1
fi
echo "SIG release successfully created for VHD build with ID: $VHD_BUILD_ID"
echo "release URL: https://msazure.visualstudio.com/CloudNativeCompute/_releaseProgress?_a=release-pipeline-progress&releaseId=$RELEASE_ID"

Expand Down

0 comments on commit 022487d

Please sign in to comment.