Skip to content

Commit

Permalink
DNI: make github action send notification to slack
Browse files Browse the repository at this point in the history
  • Loading branch information
kaizhangNV committed May 23, 2024
1 parent a4cc5b0 commit 06f16c5
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/debug-github-slack.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Github-Slack-Notification

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-20.04
steps:
- name: Run some commands
id: run-commands
run: |
echo "Hello, World!"
exit 0
- name: Send custom JSON data to Slack workflow
id: slack
if : always()
uses: slackapi/[email protected]
with:
payload: |
{
"CTS-Nightly": "CTS nightly status: ${{ job.status }}: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}"
}
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}

0 comments on commit 06f16c5

Please sign in to comment.