Skip to content

Commit 368642a

Browse files
openshift-pipelines-botopenshift-pipelines-bot
authored andcommitted
[bot:main] update konflux configuration
Generated by workflow [Generate konflux configurations](https://github.com/openshift-pipelines/hack/actions/runs/29755805310) Triggered by divyansh42
1 parent ccfcea0 commit 368642a

1 file changed

Lines changed: 56 additions & 0 deletions

File tree

.github/workflows/slack-notify-on-failure.yaml

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,63 @@ jobs:
1616
runs-on: ubuntu-latest
1717
if: ${{ github.event.workflow_run.conclusion == 'failure' }}
1818
steps:
19+
- name: Send Slack notification for auto-merge-upstream
20+
if: ${{ github.event.workflow_run.name == 'auto-merge-upstream' }}
21+
uses: slackapi/slack-github-action@v2.1.0
22+
with:
23+
webhook: ${{ secrets.SLACK_WEBHOOK_URL }}
24+
webhook-type: incoming-webhook
25+
payload: |
26+
{
27+
"blocks": [
28+
{
29+
"type": "header",
30+
"text": {
31+
"type": "plain_text",
32+
"text": "🔴 Workflow Failure: ${{ github.event.workflow_run.name }} in ${{ github.event.workflow_run.repository.name }}"
33+
}
34+
},
35+
{
36+
"type": "section",
37+
"fields": [
38+
{
39+
"type": "mrkdwn",
40+
"text": "*Repository:*\n${{ github.event.workflow_run.repository.full_name }}"
41+
},
42+
{
43+
"type": "mrkdwn",
44+
"text": "*Workflow:*\n${{ github.event.workflow_run.name }}"
45+
},
46+
{
47+
"type": "mrkdwn",
48+
"text": "*Branch:*\n${{ github.event.workflow_run.head_branch }}"
49+
}
50+
]
51+
},
52+
{
53+
"type": "section",
54+
"text": {
55+
"type": "mrkdwn",
56+
"text": "<!subteam^S04NUBJ20RG> please investigate and fix this failure.\nReach out to the release captain if you need assistance."
57+
}
58+
},
59+
{
60+
"type": "actions",
61+
"elements": [
62+
{
63+
"type": "button",
64+
"text": {
65+
"type": "plain_text",
66+
"text": "View Run"
67+
},
68+
"url": "${{ github.event.workflow_run.html_url }}"
69+
}
70+
]
71+
}
72+
]
73+
}
1974
- name: Send Slack notification
75+
if: ${{ github.event.workflow_run.name != 'auto-merge-upstream' }}
2076
uses: slackapi/slack-github-action@v2.1.0
2177
with:
2278
webhook: ${{ secrets.SLACK_WEBHOOK_URL }}

0 commit comments

Comments
 (0)