From 272a65326e2810acce370f57b0a0eca2e7708631 Mon Sep 17 00:00:00 2001 From: "j.dev" Date: Tue, 4 Feb 2025 12:38:25 -0800 Subject: [PATCH] chore(4844): send RocketChat notification when GitHub pages deployment fails --- .github/workflows/mkdocs.yml | 14 ++++++++++++++ .../{localdev-test.yml => test-sandbox.yml} | 0 2 files changed, 14 insertions(+) rename .github/workflows/{localdev-test.yml => test-sandbox.yml} (100%) diff --git a/.github/workflows/mkdocs.yml b/.github/workflows/mkdocs.yml index 61a303f41..c51580ba6 100644 --- a/.github/workflows/mkdocs.yml +++ b/.github/workflows/mkdocs.yml @@ -4,6 +4,10 @@ on: push: branches: - main + paths: + - .github/workflows/mkdocs.yml + - docs/** + - README.md concurrency: group: ${{ github.workflow }}-${{ github.ref }} @@ -33,3 +37,13 @@ jobs: uses: JamesIves/github-pages-deploy-action@v4.7.2 with: folder: site + + - name: Notify RocketChat on Failure + if: failure() + uses: ./.github/actions/rocketchat-notification + with: + webhook-url: ${{ secrets.ROCKETCHAT_WEBHOOK_URL }} + data: | + { + "text": ":warning: Deployment to GitHub Pages failed! [Investigate here](https://github.com/bcgov/platform-services-registry/actions/workflows/mkdocs.yml)" + } diff --git a/.github/workflows/localdev-test.yml b/.github/workflows/test-sandbox.yml similarity index 100% rename from .github/workflows/localdev-test.yml rename to .github/workflows/test-sandbox.yml