Merge pull request #21544 from medyagh/iso_fail_comment_fix
ci: fix failed ISO not commenting on PRpull/21645/head
commit
dfb4f364ff
|
|
@ -65,16 +65,23 @@ else
|
||||||
export ISO_BUCKET
|
export ISO_BUCKET
|
||||||
fi
|
fi
|
||||||
|
|
||||||
make release-iso | tee iso-logs.txt
|
if ! make release-iso 2>&1 | tee iso-logs.txt; then
|
||||||
# Abort with error message if above command failed
|
# Exit of `make` (PIPESTATUS[0]); fallback to 1 if unavailable
|
||||||
ec=$?
|
ec=${PIPESTATUS[0]:-1}
|
||||||
if [ $ec -gt 0 ]; then
|
|
||||||
if [ "$release" = false ]; then
|
# Only comment on non-release; default release=false if unset
|
||||||
gh pr comment ${ghprbPullId} --body "Hi ${ghprbPullAuthorLoginMention}, building a new ISO failed.
|
if [[ ${release:-false} != "true" ]]; then
|
||||||
See the logs at: https://storage.cloud.google.com/minikube-builds/logs/${ghprbPullId}/${ghprbActualCommit::7}/iso_build.txt
|
body="$(cat <<'EOF'
|
||||||
"
|
Hi ${ghprbPullAuthorLoginMention}, building a new ISO failed for Commit ${ghprbActualCommit}
|
||||||
fi
|
See the logs at:
|
||||||
exit $ec
|
https://storage.cloud.google.com/minikube-builds/logs/${ghprbPullId}/${ghprbActualCommit::7}/iso_build.txt
|
||||||
|
EOF
|
||||||
|
"
|
||||||
|
|
||||||
|
gh pr comment "${ghprbPullId}" --body "$body"
|
||||||
|
|
||||||
|
fi
|
||||||
|
exit "$ec"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
git config user.name "minikube-bot"
|
git config user.name "minikube-bot"
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue