deploy-vercel-supabase
Skill12 starsChanged 46 days agoMITView on GitHub
Walk a vibe-coder through deploying a Next.js + Supabase project to Vercel + Supabase production for the first time. Activated when the user says "vamos publicar", "como coloca no ar", "deploy", or after Sprint 1 ships and the app needs a public URL.
- Reads credentials
In this repository28 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- business-plan-impact-reviewSkill
- codemapSkill
- cost-watchdogSkill
- daily-standupSkill
- decision-logSkill
- feature-scaffoldSkill
- first-100-usersSkill
- grow-sustainablySkill
- multi-ai-reviewSkill
- os-self-testSkill
- pitchSkill
- plain-portuguese-explainerSkill
- privacy-auditSkill
- processizeSkill
- product-briefSkill
- project-genesisSkill
- prototype-labSkill
- registry-pickSkill
- release-checkSkill
- research-wavesSkill
- rollback-safeSkill
- secrets-disciplineSkill
- secrets-scanSkill
- sprint-managementSkill
- sprint-roadmapSkill
- usage-monitorSkill
- verify-build-worksSkill
The file
We split this skill into the rules it gives an agent
5 rules. About 0 are common, 3 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈3
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- could be automatic: a setting could enforce it
- Very specific: line 83
Don't paste production env vars in chat.
- Very specific: line 84
Don't commit a .env.production file.
- Distinctive: line 85
Don't promote a dev Supabase project to prod — crie um novo.
- Distinctive: line 86
Don't enable Supabase Realtime on tables that don't need it.
- Distinctive: line 87
Don't skip the post-deploy verification.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Deploy: Vercel + Supabase
When to run this skill
- User says "vamos publicar" / "colocar no ar" / "fazer o deploy" / "como hospedar".
- Sprint 1 implementation is done locally and the user wants to share a link.
launch-agentrequires a public URL.
Pre-deploy gate
Block deploy if any fail:
- App builds locally (
npm run buildexits 0). .env.localhas all required variables and they work locally..env.exampleis up to date (usesecrets-discipline).- No literal secret committed.
- Database migrations checked into the repo (
supabase/migrations/*.sql). - At least one user can sign up + sign in locally.
Step-by-step (plain Portuguese)
1. Supabase production project
- supabase.com → Dashboard → New Project. Nome:
<project-name>-prod. Region:sa-east-1para Brasil. - Senha do banco: gerar e guardar no
.env.localda máquina, NUNCA no repo. - Copiar
URLeanon keyda seção API. - Aplicar migrations:
supabase link --project-ref <ref> supabase db push - Email auth: habilitar magic link, definir Site URL (próximo passo).
2. Vercel project
- vercel.com → New Project → Import from GitHub.
- Framework: Next.js (auto-detect).
- Environment variables: copiar do
.env.example, preencher com valores de produção:SUPABASE_URL,SUPABASE_ANON_KEY(passo 1).SUPABASE_SERVICE_ROLE_KEY(NUNCA "expose to client").NEXTAUTH_URL= URL Vercel.NEXTAUTH_SECRET=openssl rand -base64 32.- Demais (Stripe, Resend, Anthropic) conforme integrações.
- Deploy.
3. First-deploy verification
- Build do Vercel passou.
- URL responde 200.
- Sign-up com email novo funciona end-to-end.
- Magic link cai na inbox.
- Sign-in redireciona pra dashboard.
- Logout funciona.
- Nenhuma chave aparece na aba Network.
Se falhar: abrir Vercel logs + Supabase logs juntos, hand-off para bug-triage-agent.
4. Custom domain (opcional)
- Comprar domínio (Registro.br / Namecheap).
- Vercel → Settings → Domains → add domain. Configurar DNS.
- Atualizar
NEXTAUTH_URLe SupabaseSite URL. - Re-deploy.
5. Post-deploy
- Adicionar Sentry (consultar
cost-watchdogantes). - Ativar Vercel Analytics.
- Rodar
usage-monitor24h depois. legal-compliance-agentANTES de divulgar publicamente.
Vibe coder explanation
Deploy é tirar o app do seu computador e colocar num servidor que o mundo acessa 24/7. Vercel cuida do servidor (você não precisa entender o que é "container"). Supabase cuida do banco. Sua parte é apertar os botões na ordem certa — eu te guio.
Do NOT
- Don't paste production env vars in chat. Use the dashboard or
vercel env add. - Don't commit a
.env.productionfile. - Don't promote a dev Supabase project to prod — crie um novo.
- Don't enable Supabase Realtime on tables that don't need it.
- Don't skip the post-deploy verification.
Common pitfalls
| Sintoma | Causa provável | Fix |
| 500 na primeira página | Env vars faltando | Conferir Vercel env vs .env.example. |
| Magic link não chega | Site URL Supabase != Vercel URL | Atualizar Authentication → URL Configuration. |
| Auth callback redireciona pro localhost | NEXTAUTH_URL errada | Atualizar env var + redeploy. |
| Build falha em prod, passa local | Node version diferente | Definir engines.node no package.json. |
| 401 nas API routes | service_role_key exposta no cliente | Rodar secrets-discipline. |
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

