diff --git a/.github/workflows/add-labels-standardized.yaml b/.github/workflows/add-labels-standardized.yaml index 59ca6b2..c7f1c7a 100644 --- a/.github/workflows/add-labels-standardized.yaml +++ b/.github/workflows/add-labels-standardized.yaml @@ -15,3 +15,12 @@ jobs: ORG_MEMBERSHIP_TOKEN: ${{ secrets.ORG_MEMBERSHIP_TOKEN }} SENZING_MEMBERS: ${{ secrets.SENZING_MEMBERS }} uses: senzing-factory/build-resources/.github/workflows/add-labels-to-issue.yaml@v2 + + slack-notification: + needs: [add-issue-labels] + if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.add-issue-labels.outputs.job-status) }} + secrets: + SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }} + uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v2 + with: + job-status: ${{ needs.add-issue-labels.outputs.job-status }} diff --git a/.github/workflows/add-to-project-garage-dependabot.yaml b/.github/workflows/add-to-project-garage-dependabot.yaml index 125bc58..f71293e 100644 --- a/.github/workflows/add-to-project-garage-dependabot.yaml +++ b/.github/workflows/add-to-project-garage-dependabot.yaml @@ -14,3 +14,12 @@ jobs: uses: senzing-factory/build-resources/.github/workflows/add-to-project-dependabot.yaml@v2 with: project: ${{ vars.SENZING_PROJECT_GARAGE }} + + slack-notification: + needs: [add-to-project-dependabot] + if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.add-to-project-dependabot.outputs.job-status) }} + secrets: + SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }} + uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v2 + with: + job-status: ${{ needs.add-to-project-dependabot.outputs.job-status }} diff --git a/.github/workflows/add-to-project-garage.yaml b/.github/workflows/add-to-project-garage.yaml index 8397880..a8b70f2 100644 --- a/.github/workflows/add-to-project-garage.yaml +++ b/.github/workflows/add-to-project-garage.yaml @@ -18,3 +18,12 @@ jobs: classic: false project-number: ${{ vars.SENZING_PROJECT_GARAGE }} org: ${{ vars.SENZING_GITHUB_ACCOUNT_NAME }} + + slack-notification: + needs: [add-to-project] + if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.add-to-project.outputs.job-status) }} + secrets: + SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }} + uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v2 + with: + job-status: ${{ needs.add-to-project.outputs.job-status }} diff --git a/.github/workflows/go-proxy-pull.yaml b/.github/workflows/go-proxy-pull.yaml index fd1cb33..a4ea2b1 100644 --- a/.github/workflows/go-proxy-pull.yaml +++ b/.github/workflows/go-proxy-pull.yaml @@ -10,6 +10,8 @@ permissions: jobs: go-proxy-pull: + outputs: + status: ${{ job.status }} runs-on: ubuntu-latest steps: @@ -17,3 +19,12 @@ jobs: uses: andrewslotin/go-proxy-pull-action@v1.3.0 with: import_path: github.com/${{ github.repository }} + + slack-notification: + needs: [go-proxy-pull] + if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.go-proxy-pull.outputs.status ) }} + secrets: + SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }} + uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v2 + with: + job-status: ${{ needs.go-proxy-pull.outputs.status }} diff --git a/.github/workflows/go-test-linux.yaml b/.github/workflows/go-test-linux.yaml index e36a855..f9b1314 100644 --- a/.github/workflows/go-test-linux.yaml +++ b/.github/workflows/go-test-linux.yaml @@ -8,6 +8,8 @@ permissions: jobs: go-test-linux: name: "Go test with Senzing: ${{ matrix.senzingsdk-version }}; OS: ${{ matrix.os }}; Go: ${{ matrix.go }}" + outputs: + status: ${{ job.status }} runs-on: ${{ matrix.os }} strategy: matrix: @@ -55,3 +57,12 @@ jobs: uses: senzing-factory/build-resources/.github/workflows/go-coverage.yaml@v2 with: coverage-config: ./.github/coverage/testcoverage.yaml + + slack-notification: + needs: [go-test-linux, coverage] + if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.go-test-linux.outputs.status ) && contains(fromJSON('["failure", "cancelled"]'), needs.coverage.outputs.job-status ) && github.ref_name == github.event.repository.default_branch }} + secrets: + SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }} + uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v2 + with: + job-status: ${{ needs.go-test-linux.outputs.status && needs.coverage.outputs.job-status }} diff --git a/.github/workflows/make-go-github-file.yaml b/.github/workflows/make-go-github-file.yaml index 339959e..8367ca8 100644 --- a/.github/workflows/make-go-github-file.yaml +++ b/.github/workflows/make-go-github-file.yaml @@ -16,3 +16,12 @@ jobs: SENZING_GITHUB_GPG_PASSPHRASE: ${{ secrets.SENZING_GITHUB_GPG_PASSPHRASE }} SENZING_GITHUB_GPG_PRIVATE_KEY: ${{ secrets.SENZING_GITHUB_GPG_PRIVATE_KEY }} uses: senzing-factory/build-resources/.github/workflows/make-go-github-file.yaml@v2 + + slack-notification: + needs: [make-go-github-file] + if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.make-go-github-file.outputs.job-status) }} + secrets: + SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }} + uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v2 + with: + job-status: ${{ needs.make-go-github-file.outputs.job-status }} diff --git a/.github/workflows/make-go-tag.yaml b/.github/workflows/make-go-tag.yaml index a4e0646..55b92e5 100644 --- a/.github/workflows/make-go-tag.yaml +++ b/.github/workflows/make-go-tag.yaml @@ -11,6 +11,8 @@ permissions: jobs: make-go-tag: name: Make a vM.m.P tag + outputs: + status: ${{ job.status }} runs-on: ubuntu-latest steps: @@ -19,3 +21,12 @@ jobs: - name: Make go version tag uses: senzing-factory/github-action-make-go-tag@v1 + + slack-notification: + needs: [make-go-tag] + if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.make-go-tag.outputs.status ) }} + secrets: + SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }} + uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v2 + with: + job-status: ${{ needs.make-go-tag.outputs.status }}