Skip to content

Commit

Permalink
Merge pull request #1270 from likewhatevs/fix-periodic-job-notifications
Browse files Browse the repository at this point in the history
Fix periodic job notifications
  • Loading branch information
likewhatevs authored Jan 30, 2025
2 parents f007d19 + 6169548 commit c7ba8f2
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 10 deletions.
10 changes: 6 additions & 4 deletions .github/workflows/bpf-next-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ jobs:
fail-fast: false
steps:
# prevent cache permission errors
- run: sudo chown root /usr/bin/tar && sudo chmod u+s /usr/bin/tar
- run: sudo chown root /usr/bin/tar && sudo chmod u+s /usr/bin/tar
- uses: actions/checkout@v4
- uses: Swatinem/rust-cache@v2
with:
Expand All @@ -92,7 +92,7 @@ jobs:
path: |
/usr/lib/virtiofsd
key: virtiofsd-binary
- if: ${{ steps.cache-virtiofsd.outputs.cache-hit != 'true' }}
- if: ${{ steps.cache-virtiofsd.outputs.cache-hit != 'true' }}
run: cargo install virtiofsd && sudo cp -a ~/.cargo/bin/virtiofsd /usr/lib/

# get latest head commit of sched_ext for-next
Expand Down Expand Up @@ -157,7 +157,7 @@ jobs:
compression-level: 9
notify-job:
runs-on: ubuntu-latest
if: ${{ (needs.integration-test.result == 'failure' || needs.integration-test.result == 'cancelled') }}
if: ${{ always() && (needs.integration-test.result == 'failure' || needs.integration-test.result == 'cancelled') }}
needs:
- integration-test
steps:
Expand All @@ -166,8 +166,10 @@ jobs:
uses: rtCamp/action-slack-notify@v2
env:
SLACK_USERNAME: ci
SLACK_ICON: https://www.dictionary.com/e/wp-content/uploads/2018/03/thisisfine-1.jpg
SLACK_TITLE: Workflow ${{ needs.integration-test.result }}
MSG_MINIMAL: bpf-next ci job failed.
SLACK_MESSAGE: bpf-next ci job failed.
SLACK_COLOR: failure
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK_URL }}


8 changes: 5 additions & 3 deletions .github/workflows/for-next-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ jobs:

notify-job:
runs-on: ubuntu-latest
if: ${{ (needs.integration-test.result == 'failure' || needs.integration-test.result == 'cancelled') }}
if: ${{ always() && (needs.integration-test.result == 'failure' || needs.integration-test.result == 'cancelled') }}
needs:
- integration-test
steps:
Expand All @@ -356,7 +356,9 @@ jobs:
uses: rtCamp/action-slack-notify@v2
env:
SLACK_USERNAME: ci
SLACK_ICON: https://www.dictionary.com/e/wp-content/uploads/2018/03/thisisfine-1.jpg
SLACK_TITLE: Workflow ${{ needs.integration-test.result }}
MSG_MINIMAL: for-next ci job failed.
SLACK_MESSAGE: sched_ext/for-next ci job failed.
SLACK_COLOR: failure
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK_URL }}

8 changes: 5 additions & 3 deletions .github/workflows/stable.yml
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ jobs:

notify-job:
runs-on: ubuntu-latest
if: ${{ (needs.integration-test.result == 'failure' || needs.integration-test.result == 'cancelled') }}
if: ${{ always() && (needs.integration-test.result == 'failure' || needs.integration-test.result == 'cancelled') }}
needs:
- integration-test
steps:
Expand All @@ -167,7 +167,9 @@ jobs:
uses: rtCamp/action-slack-notify@v2
env:
SLACK_USERNAME: ci
SLACK_ICON: https://www.dictionary.com/e/wp-content/uploads/2018/03/thisisfine-1.jpg
SLACK_TITLE: Workflow ${{ needs.integration-test.result }}
MSG_MINIMAL: stable ci job failed.
SLACK_MESSAGE: stable ci job failed.
SLACK_COLOR: failure
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK_URL }}

0 comments on commit c7ba8f2

Please sign in to comment.