Skip to content

Commit a08ef25

Browse files
pw-ppodhajskiManul from Pathway
authored andcommitted
ci(actions): fix slack alert (#7692)
GitOrigin-RevId: 0da6646c72980381e3de376adad19b49238e8b53
1 parent 798e303 commit a08ef25

File tree

2 files changed

+4
-7
lines changed

2 files changed

+4
-7
lines changed

.github/workflows/package_test.yml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -129,20 +129,18 @@ jobs:
129129
id: slack
130130
uses: slackapi/[email protected]
131131
with:
132-
# For posting a simple plain text message
132+
webhook: ${{ secrets.SLACK_WEBHOOK_URL }}
133+
webhook-type: webhook-trigger
133134
payload: |
134135
{
135136
"text": "Repository: ${{ github.repository }}\nAction name: ${{ github.workflow }}\nGitHub Action test: failure :manul:\nPR URL: ${{ github.event.pull_request.html_url || github.event.head_commit.url }}\nAction run URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}\nPR Author: ${{ github.actor }}",
136137
"blocks": [
137138
{
138139
"type": "section",
139-
"channel": ${{ secrets.SLACK_CI_ALERT }},
140140
"text": {
141141
"type": "mrkdwn",
142142
"text": "Repository: ${{ github.repository }}\nAction name: ${{ github.workflow }}\nGitHub Action test: failure :manul:\nPR URL: ${{ github.event.pull_request.html_url || github.event.head_commit.url }}\nAction run URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}\nPR Author: ${{ github.actor }}"
143143
}
144144
}
145145
]
146146
}
147-
env:
148-
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}

.github/workflows/release.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -393,19 +393,18 @@ jobs:
393393
id: slack
394394
uses: slackapi/[email protected]
395395
with:
396+
webhook: ${{ secrets.SLACK_WEBHOOK_URL }}
397+
webhook-type: webhook-trigger
396398
payload: |
397399
{
398400
"text": "GitHub Action build result: failure :manul:\nPR URL: ${{ github.event.pull_request.html_url || github.event.head_commit.url }}\nAction run URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}\nPR Author: ${{ github.event.pull_request.user.login }}",
399401
"blocks": [
400402
{
401403
"type": "section",
402-
"channel": ${{ secrets.SLACK_CI_ALERT }},
403404
"text": {
404405
"type": "mrkdwn",
405406
"text": "GitHub Action build result: failure :manul:\nPR URL: ${{ github.event.pull_request.html_url || github.event.head_commit.url }}\nAction run URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}\nPR Author: ${{ github.event.pull_request.user.login }}"
406407
}
407408
}
408409
]
409410
}
410-
env:
411-
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}

0 commit comments

Comments
 (0)