Skip to content

Commit

Permalink
Add Calypso status check (#92902)
Browse files Browse the repository at this point in the history
  • Loading branch information
alshakero authored Jul 25, 2024
1 parent 4622a31 commit c3ff395
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/is-calypso-channel-green.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Is Calypso Channel Green?
run-name: ${{ github.actor }} Checking Calypso Slack Channel Status

on:
merge_group:

jobs:
check-channel-status:
runs-on: ubuntu-latest
steps:
- run: |
STATUS=$(curl -s https://public-api.wordpress.com/wpcom/v2/calypso-slack-channel-status --header "Authorization: ${{ secrets.CALYPSO_CHANNEL_STATUS_API_SECRET }}" | xargs)
if [ "$STATUS" = "GREEN" ]; then
echo "Calypso Slack channel is green."
exit 0
elif [ "$STATUS" = "RED" ]; then
echo "Calypso Slack channel is red."
exit 1
else
echo "Calypso Slack channel status is unknown."
exit 1
fi
shell: bash

0 comments on commit c3ff395

Please sign in to comment.