Skip to content

Commit

Permalink
added slack notifications feature
Browse files Browse the repository at this point in the history
  • Loading branch information
yatrashkevich-scn committed May 29, 2024
1 parent 5d58735 commit c49b8e1
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions .github/workflows/run_deploy_dev.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -70,21 +70,22 @@ jobs:
SLACK_COLOR: failure
SLACK_CHANNEL: gha-deploy-to-dev
SLACK_WEBHOOK: ${{ secrets.SLACK_BOT_TOKEN }}
SLACK_TITLE: Run Unit Tests
SLACK_MESSAGE: 'Error when executing Unit tests!'
SLACK_TITLE: Deployment to DEV environment
SLACK_MESSAGE: 'Error when executing deployment!'

on-success:
runs-on: ubuntu-latest
if: ${{ always() && (needs.tests.result == 'success') }}
if: ${{ always() && (needs.deploy_to_ecs.result == 'success') }}
needs:
- tests
- deploy_to_ecs
steps:
- uses: actions/checkout@v4
- name: "Send Slack message on success"
uses: rtCamp/action-slack-notify@v2
env:
SLACK_COLOR: success
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK_URL_TEST_WORKFLOW }}
SLACK_TITLE: Run Unit Tests
SLACK_MESSAGE: 'Unit tests performed successfully!'
SLACK_CHANNEL: gha-deploy-to-dev
SLACK_WEBHOOK: ${{ secrets.SLACK_BOT_TOKEN }}
SLACK_TITLE: Deployment to DEV environment
SLACK_MESSAGE: 'Deployment is successfull!'

0 comments on commit c49b8e1

Please sign in to comment.