From 42c150e75343363f54989efa021239fb234a7283 Mon Sep 17 00:00:00 2001 From: Jon Mahoney Date: Sun, 18 Jul 2021 11:11:14 +0100 Subject: [PATCH] Notify on failure --- .github/workflows/build.yml | 16 ++++++++++++++++ .github/workflows/publish.yml | 8 ++++++++ 2 files changed, 24 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 9ef72f4..efdeb7d 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -36,6 +36,14 @@ jobs: run: bundle install - name: Run tests run: bundle exec rake + - name: Notify on Failure + uses: skitionek/notify-microsoft-teams@master + if: ${{ failure() }} + with: + webhook_url: ${{ secrets.TEAMS_BUILDS_WEBHOOK }} + needs: ${{ toJson(needs) }} + job: ${{ toJson(job) }} + steps: ${{ toJson(steps) }} build-next: needs: build @@ -59,3 +67,11 @@ jobs: run: bundle install - name: Run tests run: bundle exec rake + - name: Notify on Failure + uses: skitionek/notify-microsoft-teams@master + if: ${{ failure() }} + with: + webhook_url: ${{ secrets.TEAMS_BUILDS_WEBHOOK }} + needs: ${{ toJson(needs) }} + job: ${{ toJson(job) }} + steps: ${{ toJson(steps) }} diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 284e6c7..46aadfb 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -29,3 +29,11 @@ jobs: gem push *.gem env: GEM_HOST_API_KEY: ${{ secrets.RUBYGEMS_AUTH_TOKEN }} + - name: Notify on Failure + uses: skitionek/notify-microsoft-teams@master + if: ${{ failure() }} + with: + webhook_url: ${{ secrets.TEAMS_BUILDS_WEBHOOK }} + needs: ${{ toJson(needs) }} + job: ${{ toJson(job) }} + steps: ${{ toJson(steps) }}