Skip to content

Fix setup wizard middleware and env gate#20

Merged
pratikbodkhe merged 1 commit into
mainfrom
fix/setup-wizard-middleware
May 3, 2026
Merged

Fix setup wizard middleware and env gate#20
pratikbodkhe merged 1 commit into
mainfrom
fix/setup-wizard-middleware

Conversation

@pratikbodkhe
Copy link
Copy Markdown
Contributor

Summary

  • Added /api/setup and /api/admin to middleware public paths so setup wizard API calls work without auth (route handlers manage their own auth via requireAdmin())
  • Relaxed envReady gate: no longer requires JWT_SECRET env var, which is Supabase-internal and not exposed in local dev

Test plan

  • 335 E2E tests passing locally (2 consecutive runs)
  • Setup wizard loads environment check correctly
  • Continue button enabled when DB, Auth, REST, anon_key, and service_role_key are healthy

Two fixes for the setup wizard first-run flow:
1. Added /api/setup and /api/admin to middleware public paths so
   unauthenticated requests reach the route handlers (which manage
   their own auth via requireAdmin discriminated union).
2. Relaxed envReady gate to not require JWT_SECRET, which is a
   Supabase-internal concern not exposed in local dev environments.
@pratikbodkhe pratikbodkhe merged commit dc99e44 into main May 3, 2026
2 of 3 checks passed
@pratikbodkhe pratikbodkhe deleted the fix/setup-wizard-middleware branch May 3, 2026 15:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant