Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .github/workflows/keepalive.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# Free Supabase projects pause after a period of inactivity. Ping the REST API daily.
# Free Supabase projects pause after a period of inactivity. Read one row through the REST API daily.
# The bare /rest/v1/ root only answers secret keys now, so this reads a public feature flag instead.
name: Keepalive

on:
Expand All @@ -21,4 +22,4 @@ jobs:
curl --fail --silent --show-error --output /dev/null \
--retry 3 --retry-delay 10 \
-H "apikey: ${SUPABASE_PUBLISHABLE_KEY}" \
"${SUPABASE_URL}/rest/v1/"
"${SUPABASE_URL}/rest/v1/app_config?select=key&limit=1"
2 changes: 1 addition & 1 deletion docs/adr/0002-supabase-backend-with-rls-authorization.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,5 +24,5 @@ Authorization lives in Postgres:
- One place to audit. A rule written in SQL applies to the web app, the future native app and anyone poking the API with curl.
- Policy mistakes are security bugs, so pgTAP coverage for RLS is not optional (see [testing.md](../testing.md)).
- Business logic that spans rows has to be written in PL/pgSQL. That is a smaller hiring pool than TypeScript, and harder to debug.
- Free projects pause when idle. `keepalive.yml` pings the REST API daily.
- Free projects pause when idle. `keepalive.yml` reads one `app_config` row through the REST API daily.
- Moving off Supabase would mean rebuilding auth, storage and realtime. The schema and RPCs are plain Postgres and would carry over.
Loading