diff --git a/.github/workflows/chocolatey-release.yml b/.github/workflows/chocolatey-release.yml index da1e3165f..72ccb6ffc 100644 --- a/.github/workflows/chocolatey-release.yml +++ b/.github/workflows/chocolatey-release.yml @@ -1,3 +1,5 @@ +name: Chocolatey Release + on: workflow_dispatch jobs: diff --git a/.github/workflows/nightly-build.yml b/.github/workflows/nightly-build.yml index 188290d77..5e8d7edc0 100644 --- a/.github/workflows/nightly-build.yml +++ b/.github/workflows/nightly-build.yml @@ -61,7 +61,7 @@ jobs: "type": "section", "text": { "type": "mrkdwn", - "text": "*GitHub Workflow Failure*\ngo-sdk/nightly-build\n*Workflow Run*\n https://github.com/lacework/go-sdk/actions/runs/${{ github.run_id }}\n@oncall-growth-eng! There has been a failure that needs your attention. :rotating_light:" + "text": "@oncall-growth-eng! There has been a failure that needs your attention. :rotating_light:\n*GitHub Workflow Failure*\ngo-sdk/nightly-build\n*Workflow Run*\n https://github.com/lacework/go-sdk/actions/runs/${{ github.run_id }}" } } ] diff --git a/.github/workflows/prepare-release.yml b/.github/workflows/prepare-release.yml index aa64036e0..1c1e5e357 100644 --- a/.github/workflows/prepare-release.yml +++ b/.github/workflows/prepare-release.yml @@ -40,7 +40,7 @@ jobs: "type": "section", "text": { "type": "mrkdwn", - "text": "*GitHub Workflow Failure*\ngo-sdk/prepare-release\n*Workflow Run*\n https://github.com/lacework/go-sdk/actions/runs/${{ github.run_id }}\n@oncall-growth-eng! There has been a failure that needs your attention. :rotating_light:" + "text": "@oncall-growth-eng! There has been a failure that needs your attention. :rotating_light:\n*GitHub Workflow Failure*\ngo-sdk/prepare-release\n*Workflow Run*\n https://github.com/lacework/go-sdk/actions/runs/${{ github.run_id }}" } } ] diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index d7f54f9af..f04963e0e 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -98,7 +98,7 @@ jobs: "type": "section", "text": { "type": "mrkdwn", - "text": "*GitHub Workflow Failure*\ngo-sdk/release\n*Workflow Run*\n https://github.com/lacework/go-sdk/actions/runs/${{ github.run_id }}\n@oncall-growth-eng! There has been a failure that needs your attention. :rotating_light:" + "text": "@oncall-growth-eng! There has been a failure that needs your attention. :rotating_light:\n*GitHub Workflow Failure*\ngo-sdk/release\n*Workflow Run*\n https://github.com/lacework/go-sdk/actions/runs/${{ github.run_id }}" } } ] diff --git a/.github/workflows/test-build.yml b/.github/workflows/test-build.yml index 2e95cbfea..cfaa4deb8 100644 --- a/.github/workflows/test-build.yml +++ b/.github/workflows/test-build.yml @@ -54,6 +54,31 @@ jobs: # TODO Display test report + - name: Notify Slack on Failure + uses: slackapi/slack-github-action@v1.25.0 + if: failure() + with: + payload: | + { + "attachments": [ + { + "color": "#E92020", + "blocks": [ + { + "type": "section", + "text": { + "type": "mrkdwn", + "text": "@oncall-growth-eng! There has been a failure that needs your attention. :rotating_light:\n*GitHub Workflow Failure*\ngo-sdk/test-build\n*Workflow Run*\n https://github.com/lacework/go-sdk/actions/runs/${{ github.run_id }}" + } + } + ] + } + ] + } + env: + SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL_GROWTH_ENG_ALERTS }} + SLACK_WEBHOOK_TYPE: INCOMING_WEBHOOK + trigger-release: runs-on: ubuntu-latest container: @@ -71,13 +96,9 @@ jobs: echo "$GPG_SECRET_KEY" | base64 --decode | gpg --import --no-tty --batch --yes scripts/release.sh trigger - notify-on-failure: - runs-on: ubuntu-latest - needs: [run-tests, trigger-release] - steps: - name: Notify Slack on Failure uses: slackapi/slack-github-action@v1.25.0 - if: ${{ always() && contains(needs.*.result, 'failure') }} + if: failure() with: payload: | { @@ -89,7 +110,7 @@ jobs: "type": "section", "text": { "type": "mrkdwn", - "text": "*GitHub Workflow Failure*\ngo-sdk/test-build\n*Workflow Run*\n https://github.com/lacework/go-sdk/actions/runs/${{ github.run_id }}\n@oncall-growth-eng! There has been a failure that needs your attention. :rotating_light:" + "text": "@oncall-growth-eng! There has been a failure that needs your attention. :rotating_light:\n*GitHub Workflow Failure*\ngo-sdk/test-build\n*Workflow Run*\n https://github.com/lacework/go-sdk/actions/runs/${{ github.run_id }}" } } ] diff --git a/.github/workflows/update-homebrew-formula.yml b/.github/workflows/update-homebrew-formula.yml index a6f8e5de2..bafc0ad11 100644 --- a/.github/workflows/update-homebrew-formula.yml +++ b/.github/workflows/update-homebrew-formula.yml @@ -39,7 +39,7 @@ jobs: "type": "section", "text": { "type": "mrkdwn", - "text": "*GitHub Workflow Failure*\ngo-sdk/update-homebrew-formula\n*Workflow Run*\n https://github.com/lacework/go-sdk/actions/runs/${{ github.run_id }}\n@oncall-growth-eng! There has been a failure that needs your attention. :rotating_light:" + "text": "@oncall-growth-eng! There has been a failure that needs your attention. :rotating_light:\n*GitHub Workflow Failure*\ngo-sdk/update-homebrew-formula\n*Workflow Run*\n https://github.com/lacework/go-sdk/actions/runs/${{ github.run_id }}" } } ] diff --git a/.github/workflows/verify-release.yml b/.github/workflows/verify-release.yml index d825b626e..27907b017 100644 --- a/.github/workflows/verify-release.yml +++ b/.github/workflows/verify-release.yml @@ -38,7 +38,7 @@ jobs: "type": "section", "text": { "type": "mrkdwn", - "text": "*GitHub Workflow Failure*\ngo-sdk/verify-release\n*Workflow Run*\n https://github.com/lacework/go-sdk/actions/runs/${{ github.run_id }}\n@oncall-growth-eng! There has been a failure that needs your attention. :rotating_light:" + "text": "@oncall-growth-eng! There has been a failure that needs your attention. :rotating_light:\n*GitHub Workflow Failure*\ngo-sdk/verify-release\n*Workflow Run*\n https://github.com/lacework/go-sdk/actions/runs/${{ github.run_id }}" } } ] diff --git a/.github/workflows/windows-integration.yml b/.github/workflows/windows-integration.yml index bfadf5358..c1979bdc0 100644 --- a/.github/workflows/windows-integration.yml +++ b/.github/workflows/windows-integration.yml @@ -1,3 +1,5 @@ +name: Windows Integration Tests + on: push: branches: