Slack Notifier #62
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Slack Notifier | |
on: | |
workflow_run: | |
workflows: ["TestFlight Release Deployment", "TestFlight Dev deployment", "TestFlight Staging deployment"] | |
types: | |
- completed | |
jobs: | |
notify: | |
if: ${{ github.event.workflow_run.conclusion == 'failure' }} | |
runs-on: ubuntu-latest | |
steps: | |
- name: Send notification to Slack | |
uses: slackapi/[email protected] | |
with: | |
channel-id: ${{ secrets.SLACK_CHANNEL_ID }} | |
slack-message: "💥 GitHub Action *${{ github.event.workflow_run.name }}* has failed in the *${{ github.repository }}* repository. 💥\n<${{ github.event.workflow_run.html_url }}|View the workflow run>" | |
env: | |
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }} | |