Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Discord notification for failed goth nightlies #511

Merged
merged 1 commit into from
Jul 1, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 14 additions & 2 deletions .github/workflows/goth-nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,8 @@ jobs:
uses: actions/upload-artifact@v2
if: always()
with:
name: goth-logs
path: /tmp/goth-tests
name: goth-logs
path: /tmp/goth-tests

# Only relevant for self-hosted runners
- name: Remove test logs
Expand All @@ -98,3 +98,15 @@ jobs:
# In future we'll be able to use the `--all` flag here to remove envs for
# all Python versions (https://github.com/python-poetry/poetry/issues/3208).
run: poetry env remove python3.8

- name: Send Discord notification on failure
uses: Ilshidur/[email protected]
if: failure()
env:
BRANCH_NAME: ${{ matrix.branch }}
DISCORD_AVATAR: https://i.imgur.com/EOX16Mx.jpg
DISCORD_USERNAME: 'Goth night watch'
DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }}
WORKFLOW_URL: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}
with:
args: 'Goth nightly run failed for `{{ EVENT_PAYLOAD.repository.full_name }}` on branch `{{ BRANCH_NAME }}`! {{ WORKFLOW_URL }}'