diff --git a/.github/workflows/production-heartbeat.yml b/.github/workflows/production-heartbeat.yml index f2785b089..6390a34dc 100644 --- a/.github/workflows/production-heartbeat.yml +++ b/.github/workflows/production-heartbeat.yml @@ -107,10 +107,6 @@ jobs: if: ${{ failure() || cancelled() }} shell: bash env: - # If we're here because steps failed or were skipped, then that's a critical problem. Otherwise it's a normal one. - # We can't use the `failure()` or `cancelled()` convenience methods outside of the `if` condition, hence the - # `contains()` calls. - IS_CRITICAL: ${{ contains(join(steps.*.outcome), 'failure') || contains(join(steps.*.outcome), 'skipped') }} # Build the status strings for each step as environment variables to save space later. Null retry_count values # will be replaced with `n/a` to maintain readability in the alert. CLI_INSTALL_STATUS: ${{ steps.sf_install.outcome }} after ${{ steps.sf_install.outputs.retry_count || 'n/a' }} retries @@ -120,13 +116,8 @@ jobs: RUN_LINK: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }} run: | # GHA env-vars don't have robust conditional logic, so we'll use this if-else branch to define some bash env-vars. - if [[ ${{ env.IS_CRITICAL }} == true ]]; then - ALERT_SEV="critical" - ALERT_SUMMARY="Production heartbeat script failed on ${{ runner.os }}" - else - ALERT_SEV="info" - ALERT_SUMMARY="Production heartbeat script succeeded with retries on ${{ runner.os }}" - fi + ALERT_SEV="critical" + ALERT_SUMMARY="Production heartbeat script failed on ${{ runner.os }}" # Define a helper function to create our POST request's data, to sidestep issues with nested quotations. generate_post_data() { # This is known as a HereDoc, and it lets us declare multi-line input ending when the specified limit string,