Files
spring-tools/.github/workflows/test-slack-message.yml
2023-08-01 17:16:31 -04:00

40 lines
1.1 KiB
YAML

name: Test Slack Message
on:
workflow_dispatch:
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
jobs:
slack-message:
name: Send slack message
runs-on: ubuntu-latest
steps:
- id: slack
uses: slackapi/slack-github-action@e28cf165c92ffef168d23c5c9000cffc8a25e117
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
SLACK_WEBHOOK_TYPE: INCOMING_WEBHOOK
with:
# The following message update step does not accept a channel name.
# Setting a channel ID here for consistency is highly recommended.
channel-id: 'C0188MENU2J,C4W4Q9FR9'
payload: |
{
"text": "Hello from STS4 Github Repo",
"attachments": [
{
"pretext": "Deployment started",
"color": "dbab09",
"fields": [
{
"title": "Status",
"short": true,
"value": "In Progress"
}
]
}
]
}