Skip to content

Commit

Permalink
Merge pull request #9 from ykim-akamai/ci/notify_slack_on_release
Browse files Browse the repository at this point in the history
add release-notify-slack workflow
  • Loading branch information
ykim-akamai authored Oct 28, 2024
2 parents 60622fc + c814822 commit 6c30aa8
Showing 1 changed file with 39 additions and 0 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/release-notify-slack.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Notify Dev DX Channel on Release

on:
release:
types: [published]
# if: github-token.repository == 'linode/linode_api4-python'
steps:
- name: Notify Slack - Main Message
id: main_message
uses: slackapi/[email protected]
with:
channel-id: ${{ secrets.SLACK_CHANNEL_ID }}
payload: |
{
"text": "*New Release Published in ${{ github.repository }}!*",
"blocks": [
{
"type": "section",
"text": {
"type": "mrkdwn",
"text": "*<${{ github.event.release.html_url }}|${{ github.repository }}: ${{ github.event.release.tag_name }}>* is now live! :tada:"
}
}
]
}
env:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}

- name: Notify Slack - Threaded Release Notes
uses: slackapi/[email protected]
with:
channel-id: ${{ secrets.SLACK_CHANNEL_ID }}
payload: |
{
"thread_ts": "${{ steps.main_message.outputs.ts }}",
"text": "Release Notes:\n${{ github.event.release.body }}"
}
env:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}

0 comments on commit 6c30aa8

Please sign in to comment.