mirror of
https://github.com/sdkman/sdkman-cli.git
synced 2026-04-17 13:38:03 -04:00
chore: notify Chloé on release build failure
This commit is contained in:
committed by
Marco Vermeulen
parent
f6524ce2a6
commit
d734ef2a68
21
.github/workflows/release.yml
vendored
21
.github/workflows/release.yml
vendored
@@ -47,3 +47,24 @@ jobs:
|
||||
run: bin/release-binary.sh "$MONGO_URL" "$MONGO_USERNAME" "$MONGO_PASSWORD" "$RELEASE_TAG" "stable"
|
||||
- name: Tweet about it
|
||||
run: ./gradlew -Penv=stable -Prelease=${{ github.event.inputs.version }} jreleaserAnnounce
|
||||
|
||||
notify-failure:
|
||||
name: "Notify on Failure"
|
||||
runs-on: ubuntu-latest
|
||||
needs: [build]
|
||||
if: failure()
|
||||
steps:
|
||||
- name: Notify Chloé
|
||||
env:
|
||||
REPO: ${{ github.repository }}
|
||||
RUN_URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
|
||||
run: |
|
||||
MSG="❌ Release build failed: ${REPO}"
|
||||
MSG+=$'\nRun: '"${RUN_URL}"
|
||||
PAYLOAD=$(jq -n --arg msg "$MSG" --arg name "GitHub CI" \
|
||||
'{message: $msg, name: $name, deliver: true, channel: "discord", to: "user:918237603617206303"}')
|
||||
curl -sf -X POST \
|
||||
-H "Authorization: Bearer ${{ secrets.OPENCLAW_HOOK_TOKEN }}" \
|
||||
-H "Content-Type: application/json" \
|
||||
-d "$PAYLOAD" \
|
||||
"${{ secrets.OPENCLAW_HOOK_URL }}"
|
||||
|
||||
Reference in New Issue
Block a user