Skip to content

Commit d7f4feb

Browse files
authored
BUILD-7788 Migrate slack notification
1 parent 72d3ee7 commit d7f4feb

File tree

1 file changed

+18
-7
lines changed

1 file changed

+18
-7
lines changed

.github/workflows/slack_notify.yml

Lines changed: 18 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,24 @@
11
---
22
name: Slack Notifications
33
on:
4-
check_run:
5-
types: [rerequested, completed]
4+
check_suite:
5+
types: [completed]
6+
7+
permissions:
8+
actions: read
9+
contents: read
10+
checks: read
11+
id-token: write
612

713
jobs:
814
slack-notifications:
9-
permissions:
10-
id-token: write # to authenticate via OIDC
11-
uses: SonarSource/gh-action_build-notify/.github/workflows/main.yaml@v1
12-
with:
13-
slackChannel: squad-mobile
15+
if: >-
16+
contains(fromJSON('["main", "master"]'), github.event.check_suite.head_branch) || startsWith(github.event.check_suite.head_branch, 'dogfood-') || startsWith(github.event.check_suite.head_branch, 'branch-')
17+
runs-on: ubuntu-latest
18+
steps:
19+
- name: Send Slack Notification
20+
env:
21+
GITHUB_TOKEN: ${{ github.token }}
22+
uses: SonarSource/gh-action_slack-notify@v1
23+
with:
24+
slackChannel: squad-mobile

0 commit comments

Comments
 (0)