spiff-arena/.github/workflows/slack_notify.yml

18 lines
668 B
YAML
Raw Normal View History

2023-05-02 02:03:23 +00:00
name: Slack Notification
on:
workflow_run:
workflows: ["Backend Tests", "Frontend Tests", "Docker Image For Main Builds", "Release Builds"]
2023-05-02 02:03:23 +00:00
types: [completed]
2023-05-02 00:20:41 +00:00
jobs:
2023-05-02 02:03:23 +00:00
send_notification:
2023-05-02 00:20:41 +00:00
runs-on: ubuntu-latest
steps:
2023-05-02 12:10:41 +00:00
- name: Notify on Backend Tests failure
if: ${{ github.event.workflow_run.conclusion != 'success' }}
2023-05-02 02:03:23 +00:00
run: |
curl -X POST -H 'Content-type: application/json' \
--data '{"text":"spiff-arena workflow <${{ github.event.workflow_run.html_url }}|${{ github.event.workflow.name }}> ended with conclusion ${{github.event.workflow_run.conclusion}}!"}' \
2023-05-02 02:03:23 +00:00
${{ secrets.SLACK_WEBHOOK_URL }}