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 slack notifications for image build failures #2019

Merged
merged 1 commit into from
Jan 28, 2025
Merged
Show file tree
Hide file tree
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
20 changes: 20 additions & 0 deletions .github/workflows/collector-builder.yml
Original file line number Diff line number Diff line change
Expand Up @@ -237,3 +237,23 @@ jobs:
dst-image: quay.io/rhacs-eng/collector-builder:${{ env.COLLECTOR_BUILDER_TAG }}
username: ${{ secrets.QUAY_RHACS_ENG_RW_USERNAME }}
password: ${{ secrets.QUAY_RHACS_ENG_RW_PASSWORD }}

notify:
runs-on: ubuntu-24.04
if: always() && contains(join(needs.*.result, ','), 'failure') && github.event_name != 'pull_request'
needs:
- build-builder-image
- create-multiarch-manifest
- retag-x86-image
steps:
- name: Slack notification
uses: rtCamp/action-slack-notify@v2
env:
SLACK_WEBHOOK: ${{ secrets.SLACK_COLLECTOR_ONCALL_WEBHOOK }}
SLACK_CHANNEL: team-acs-collector-oncall
SLACK_COLOR: failure
SLACK_LINK_NAMES: true
SLACK_TITLE: "Builder image build has failed"
MSG_MINIMAL: actions url,commit
SLACK_MESSAGE: |
@acs-collector-oncall
21 changes: 21 additions & 0 deletions .github/workflows/collector.yml
Original file line number Diff line number Diff line change
Expand Up @@ -319,3 +319,24 @@ jobs:
dst-image: ${{ env.RHACS_ENG_IMAGE }}-latest
username: ${{ secrets.QUAY_RHACS_ENG_RW_USERNAME }}
password: ${{ secrets.QUAY_RHACS_ENG_RW_PASSWORD }}

notify:
runs-on: ubuntu-24.04
if: always() && contains(join(needs.*.result, ','), 'failure') && github.event_name != 'pull_request'
needs:
- build-collector-image
- build-collector-image-remote-vm
- create-multiarch-manifest
- retag-x86-image
steps:
- name: Slack notification
uses: rtCamp/action-slack-notify@v2
env:
SLACK_WEBHOOK: ${{ secrets.SLACK_COLLECTOR_ONCALL_WEBHOOK }}
SLACK_CHANNEL: team-acs-collector-oncall
SLACK_COLOR: failure
SLACK_LINK_NAMES: true
SLACK_TITLE: "Collector image build has failed"
MSG_MINIMAL: actions url,commit
SLACK_MESSAGE: |
@acs-collector-oncall
19 changes: 19 additions & 0 deletions .github/workflows/integration-test-containers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -185,3 +185,22 @@ jobs:
- name: Build and Push containers
run: |
make -C "${{ matrix.directory }}" build-and-push

notify:
runs-on: ubuntu-24.04
if: always() && contains(join(needs.*.result, ','), 'failure') && github.event_name != 'pull_request'
needs:
- build-test-image
- rebuild-containers
steps:
- name: Slack notification
uses: rtCamp/action-slack-notify@v2
env:
SLACK_WEBHOOK: ${{ secrets.SLACK_COLLECTOR_ONCALL_WEBHOOK }}
SLACK_CHANNEL: team-acs-collector-oncall
SLACK_COLOR: failure
SLACK_LINK_NAMES: true
SLACK_TITLE: "Failed to rebuild test containers"
MSG_MINIMAL: actions url,commit
SLACK_MESSAGE: |
@acs-collector-oncall
Loading