chore(all): perform updates required to move to latest cdk version #4464
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This is a workflow to notify Slack of any relevant activities on Github. | |
name: Slack Notifications Workflow | |
# Controls when the action will run. | |
on: | |
issues: | |
types: [opened] | |
issue_comment: | |
types: [created] | |
pull_request: | |
types: [opened] | |
release: | |
types: [published] | |
# A workflow run is made up of one or more jobs that can run sequentially or in parallel | |
jobs: | |
slackNotification: | |
name: Slack Notifications Job | |
runs-on: ubuntu-latest | |
steps: | |
- name: Issue Slack Notification | |
if: ${{ github.event_name == 'issues' || (!github.event.issue.pull_request && github.event_name == 'issue_comment') }} | |
uses: 8398a7/action-slack@v3 | |
with: | |
status: custom | |
fields: all | |
custom_payload: | | |
{ | |
Type: 'Issue', | |
Content: `https://github.com/awslabs/aws-solutions-constructs/issues/${{ env.ISSUE_NUMBER }}` | |
} | |
env: | |
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK }} | |
ISSUE_NUMBER: ${{ github.event.issue.number }} | |
- name: PR Slack Notification | |
if: ${{ github.event_name == 'pull_request' || (github.event.issue.pull_request && github.event_name == 'issue_comment') }} | |
uses: 8398a7/action-slack@v3 | |
with: | |
status: custom | |
fields: all | |
custom_payload: | | |
{ | |
Type: 'Pull Request', | |
Content: `https://github.com/awslabs/aws-solutions-constructs/pull/${{ env.PR_NUMBER }}` | |
} | |
env: | |
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK }} | |
PR_NUMBER: ${{ github.event.number }} | |
- name: Set env | |
if: ${{ github.event_name == 'release' }} | |
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV | |
- name: Release Slack Notification | |
if: ${{ github.event_name == 'release' }} | |
uses: 8398a7/action-slack@v3 | |
with: | |
status: custom | |
fields: all | |
custom_payload: | | |
{ | |
Version: `${{ env.TAG_NAME }}`, | |
Content: `https://github.com/awslabs/aws-solutions-constructs/releases/tag/${{ env.TAG_NAME }}` | |
} | |
env: | |
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_RELEASE_WEBHOOK }} | |
TAG_NAME: ${{ env.RELEASE_VERSION }} |