CoreMVP
Deployment

Deployment

Deploy your application to production.

Overview

This is a single Next.js application. Deploy it anywhere that supports Node.js.

Production Checklist

Before deploying, ensure:

Environment Variables

  • NEXT_PUBLIC_APP_URL set to production URL
  • NEXT_PUBLIC_SUPABASE_URL set to production Supabase
  • NEXT_PUBLIC_SUPABASE_ANON_KEY set to production key
  • DATABASE_URL set to production Postgres
  • STRIPE_SECRET_KEY using live keys (not test)
  • STRIPE_WEBHOOK_SECRET for production webhook
  • NEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY using live key

Supabase

  • Create production Supabase project
  • Run ./coremvp connect supabase to create or link the project and apply migrations
  • Verify the linked database with ./coremvp connect supabase verify
  • Save the hosted Site URL and Redirect URLs in Supabase URL Configuration
  • Configure OAuth redirect URLs
  • Set up email templates

Stripe

  • Create products in live mode
  • Configure webhook endpoint: https://yourdomain.com/api/webhooks/stripe
  • Select all relevant events for webhook

Security

  • All environment variables use production values
  • HTTPS enabled (automatic on most platforms)
  • Rate limiting configured (optional)

Deployment Matrix

OptionProsCons
Docker + VPSFull control, predictable costsRequires server management
VercelEasy, auto-scaling, zero-configUsage-based pricing
RailwaySimple deploy, good free tierUsage-based pricing

Architecture

Since this is a monolithic Next.js app, deployment is straightforward:

Internet → CDN/Proxy → Next.js App → Supabase Auth / Postgres / Stripe

All API routes are bundled with the Next.js application. No separate backend deployment needed.

Quick Deploy

Vercel (Easiest)

./coremvp connect supabase
./coremvp connect supabase verify
./coremvp connect vercel
./coremvp deploy vercel

Before proving hosted Auth, open Supabase URL Configuration, set Site URL to https://<project-name>.vercel.app, add https://<project-name>.vercel.app/** to Redirect URLs, and save.

Production is the default deploy target. Preview deploys are advanced until they have isolated Supabase, Stripe, and webhook values. The default ./coremvp connect vercel syncs .env to Vercel Production only.

Docker

docker build -t myapp .
docker run -p 3000:3000 --env-file .env.local myapp

Railway

  1. Connect GitHub repo
  2. Add environment variables
  3. Deploy

See individual guides for detailed steps.

Was this page helpful?

On this page