Skip to content

Commit

Permalink
Intentionally fail integtest and post message using block kit format
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewmogan committed Sep 26, 2024
1 parent e4e8170 commit 6fdce5f
Showing 1 changed file with 16 additions and 7 deletions.
23 changes: 16 additions & 7 deletions .github/workflows/nightly-v5-integtest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ jobs:
uses: actions/checkout@v4
with:
repository: DUNE-DAQ/listrev
ref: develop
ref: amogan/intentional_integtest_failure
path: listrev

- name: setup release and run tests
Expand Down Expand Up @@ -104,15 +104,24 @@ jobs:
name: send slack message
needs: integration_tests
steps:
- name: Send JSON data to Slack workflow
- name: Send custom JSON data to Slack workflow
id: slack
uses: slackapi/slack-github-action@v1.26.0
uses: slackapi/slack-github-action@v1.27.0
with:
# Variables used by the Slack workflow
# For posting a rich message using Block Kit
payload: |
{
"workflow_name": "${{ github.workflow }}",
"workflow_url": "${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}"
"text": "!!!GitHub Action Failure!!!",
"blocks": [
{
"type": "section",
"text": {
"type": "mrkdwn",
"text": "The GitHub Action ${{ github.workflow }} has failed! For more information, see ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}"
}
}
]
}
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_INCOMING_WEBHOOK_URL }}
SLACK_WEBHOOK_TYPE: INCOMING_WEBHOOK

0 comments on commit 6fdce5f

Please sign in to comment.