supabase-multi-env-setup
Skill by jeremylongshore
Sets up Supabase across development, staging, and production with separate projects, per-environment secrets, and safe migration promotion. It is for developers who need to isolate dev data from production.
Install supabase-multi-env-setup
Built from the published package, never by AI.
git clone --depth 1 https://github.com/jeremylongshore/tons-of-skills-marketplace /tmp/tons-of-skills-marketplace && mkdir -p ~/.claude/skills && cp -r /tmp/tons-of-skills-marketplace/skills/.curated/supabase-multi-env-setup ~/.claude/skills/supabase-multi-env-setupRun in your terminal. Claude Code loads skills from ~/.claude/skills automatically.
Step-by-step: install supabase-multi-env-setup in Claude Code
git clone --depth 1 https://github.com/jeremylongshore/tons-of-skills-marketplace /tmp/tons-of-skills-marketplace && mkdir -p ~/.gemini/antigravity-cli/skills && cp -r /tmp/tons-of-skills-marketplace/skills/.curated/supabase-multi-env-setup ~/.gemini/antigravity-cli/skills/supabase-multi-env-setupAntigravity CLI loads skills from ~/.gemini/antigravity-cli/skills, or .agents/skills for one project.
Step-by-step: install supabase-multi-env-setup in Antigravity CLI
Skills can run scripts on your machine. Some need an API key: check the README.
About
This skill configures a three-tier Supabase architecture: local development, staging, and production. Each environment gets its own project with its own URL, API keys, database, and RLS policies. Schema changes live in shared migrations that are promoted in order, from local to staging to production, using supabase db push.
The skill also covers environment-aware client setup, with browser clients using the anon key and server clients using the service-role key. Destructive helpers are blocked in production by a requireNonProduction guard. It describes database branching for preview deployments and GitHub Actions workflows with a production approval gate. It is aimed at teams setting up a new project with multiple environments or moving from a single-project setup.
Written from the project's SKILL.md and checked against it.
What it can do
- Environment file layoutDefines .env.local, .env.staging, and .env.production, with credential files gitignored.
- Project linkingRe-links the Supabase CLI to the target project before db push or functions deploy.
- Environment-aware clientsBuilds browser and server Supabase clients from the detected environment.
- Production guardProvides requireNonProduction() to block seeds and resets from running in production.
- Migration promotionPromotes schema changes from local to staging to production with supabase db push.
- Database branchingCreates isolated database branches for preview deployments on the Pro plan.
- CI/CD workflowsDescribes GitHub Actions that deploy migrations and Edge Functions per environment with production approval.
- TypeScript typesGenerates database.types.ts from the local or linked project schema.
What you need
- Three separate Supabase projects (dev, staging, production)
- Supabase CLI
- @supabase/supabase-js v2 or later
- Node.js 22 or later
- Supabase Pro plan for database branching
- A CI secret store such as GitHub Actions Secrets or Vercel env vars
Try asking
- Set up dev, staging, and production Supabase environments for my project
- Promote my new migration from staging to production with db push
- Add a production guard so seed and reset helpers cannot run in prod
Good to know
- Database branching requires the Supabase Pro plan.
- The CLI links only one project at a time, so it must be re-linked before each push.
- seed.sql runs only on db reset, so production must use db push instead.
Security check
B- Allowed to use Write, Edit without limitsIn
SKILL.md
Checked automatically: skills/.curated/supabase-multi-env-setup/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work
Inside the skill
Allowed tools: ReadWriteEditBash(npx supabase:*)Bash(supabase:*)Bash(vercel:*)
Alternatives to supabase-multi-env-setup
All alternatives →Runs the full Next.js deployment test suite for an internal vercel/next.js pull request. It validates the commit's preview package, then dispatches the test_e2e_deploy_release.yml workflow. Meant for maintainers who explicitly ask for the entire suite.
Instruments Python AI applications with DeepEval's native tracing so their execution appears span by span in Confident AI's Observatory. It is for developers building LLM apps, agents, RAG pipelines and chatbots.
Manages Azure Container Registry through the az acr Azure CLI command group. It covers registries, images, cloud builds, ACR Tasks, tokens, geo-replication and networking. Built for developers and operators who work with ACR in Azure.
Opens, runs, and shows apps on a temporary Crabbox machine, including native desktops and web previews. It is for OpenClaw users who want an app running and visible in their chat side panel.
Runs batch and HPC workloads on GKE using job queues and parallel processing. Aimed at teams running batch pipelines, HPC simulations, or ML training jobs on Google Kubernetes Engine.
Answers questions about GKE cluster and workload costs using BigQuery billing exports and live cluster metrics. Built for platform engineers and cloud teams who need to analyze and diagnose GKE spend.
Compare with deploy-release-test, deepeval-tracing or azure-container-registry-cli
supabase-multi-env-setup: common questions
Does this skill require separate Supabase projects for each environment?
Yes. The source says each environment needs a separate project with its own URL, API keys, database, and RLS policies.
How are schema changes moved between environments?
Shared migrations are applied in order, local first, then staging, then production, using supabase db push after linking to each target.
Can database branching be used on any Supabase plan?
No. The source says database branching requires the Supabase Pro plan.
How do I install supabase-multi-env-setup?
Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.
Is supabase-multi-env-setup free?
The code is published under the MIT licence. The service it connects to may have its own pricing.
Is supabase-multi-env-setup safe to use?
It scores 76 of 100. Grades: maintenance A, licence A, quality A. Security check: grade B (allowed to use write, edit without limits). Review the code before you install. How grades work.
What are alternatives to supabase-multi-env-setup?
Similar skills: deploy-release-test, deepeval-tracing, azure-container-registry-cli, crabbox-apps.
