CI alerts #229
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
# send alerts on failed CI | |
name: CI alerts | |
on: | |
workflow_run: | |
workflows: | |
- 'CI' | |
types: | |
- 'completed' | |
jobs: | |
on-failure: | |
runs-on: ubuntu-latest | |
if: ${{ github.event.workflow_run.conclusion == 'failure' }} | |
steps: | |
# @plebbitjs telegram chat id is -1001792656766 | |
- name: "@plebbitjs telegram alert" | |
uses: appleboy/telegram-action@master | |
with: | |
to: ${{ secrets.TELEGRAM_TO }} | |
token: ${{ secrets.TELEGRAM_TOKEN }} | |
message: | | |
${{ github.event.workflow_run.name }} ${{ github.event.workflow_run.conclusion }} ${{ github.event.workflow_run.html_url }} | |
${{ github.event.workflow_run.head_repository.full_name }} ${{ github.event.workflow_run.head_branch }} | |
${{ github.event.workflow_run.head_commit.author.name }} | |
${{ github.event.workflow_run.head_commit.message }} |