Skip to content

Keep Supabase Alive #20

Keep Supabase Alive

Keep Supabase Alive #20

Workflow file for this run

# Keep Supabase free tier alive — prevents 7-day inactivity pause
#
# Pings the Supabase REST endpoint weekly. Costs $0 on GitHub Actions free tier.
# Required secrets: SUPABASE_URL, SUPABASE_ANON_KEY
name: Keep Supabase Alive
on:
schedule:
- cron: '0 0 * * 0' # Weekly — Sunday midnight UTC
workflow_dispatch:
jobs:
ping:
runs-on: ubuntu-latest
steps:
- name: Ping Supabase REST API
run: |
STATUS=$(curl -s -o /dev/null -w "%{http_code}" \
"${{ secrets.SUPABASE_URL }}/rest/v1/subscriptions?select=count&limit=0" \
-H "apikey: ${{ secrets.SUPABASE_ANON_KEY }}" \
-H "Authorization: Bearer ${{ secrets.SUPABASE_ANON_KEY }}")
echo "Supabase responded with HTTP $STATUS"
[ "$STATUS" -lt 400 ] || exit 1