SavvySolve Docs

Deployment Guide

How to deploy SavvySolve to Vercel

Deployment Guide

SavvySolve deploys to Vercel, the platform built by the creators of Next.js. This guide covers the complete deployment process from local development to production.

Architecture Overview

The deployment architecture uses:

  • Vercel for serverless compute and hosting
  • Neon for serverless Postgres database
  • Clerk for authentication
  • Telnyx for SMS/voice

Code flows through GitHub, while configuration is managed via Vercel CLI.

Prerequisites

Before deploying, ensure you have:

  1. Vercel Account - Sign up
  2. Environment variables ready (from .env.local)
  3. GitHub repository (optional, for CI/CD)

Initial Setup

1. Login to Vercel

bunx vercel login

This opens a browser for authentication.

2. Verify Authentication

bunx vercel whoami

Environment Variables

Set each environment variable for production:

# Database
bunx vercel env add DATABASE_URL production
bunx vercel env add DATABASE_URL_UNPOOLED production

# Authentication (Clerk)
bunx vercel env add CLERK_SECRET_KEY production
bunx vercel env add NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY production

# SMS/Voice (Telnyx)
bunx vercel env add TELNYX_API_KEY production
bunx vercel env add TELNYX_PHONE_NUMBER production
bunx vercel env add TELNYX_APP_ID production
bunx vercel env add TELNYX_SIP_USERNAME production
bunx vercel env add TELNYX_SIP_PASSWORD production

Each command will prompt for the value. Paste from your .env.local.

Listing Environment Variables

bunx vercel env ls

Removing Environment Variables

bunx vercel env rm VARIABLE_NAME production --yes

Deployment

Preview Deploy

Deploy a preview version (for testing):

bunx vercel

Production Deploy

Deploy to production:

bunx vercel --prod
# or
bun run deploy

View Deployments

bunx vercel ls

GitHub Integration (CI/CD)

For automatic deployments on push:

  1. Go to Vercel Dashboard
  2. Select your project → Settings → Git
  3. Connect your GitHub repository
  4. Configure:
    • Production Branch: master
    • Preview Branches: All other branches

Now every push to master auto-deploys to production.

Custom Domain

To add a custom domain:

  1. Go to Vercel Dashboard → Project → Settings → Domains
  2. Add your domain (e.g., savvysolve.io)
  3. Update DNS records as instructed

Or via CLI:

bunx vercel domains add savvysolve.io

Useful Commands

# Authentication
bunx vercel login              # Login to Vercel
bunx vercel logout             # Logout
bunx vercel whoami             # Check current account

# Deployment
bunx vercel                    # Preview deploy
bunx vercel --prod             # Production deploy
bunx vercel ls                 # List deployments

# Environment Variables
bunx vercel env ls             # List env vars
bunx vercel env add NAME       # Add env var
bunx vercel env rm NAME        # Remove env var

# Domains
bunx vercel domains ls         # List domains
bunx vercel domains add DOMAIN # Add domain

# Logs
bunx vercel logs               # View logs
bunx vercel logs --follow      # Tail logs

Vercel Limits (Free Tier)

ResourceLimit
Function size250 MB uncompressed
Bandwidth100 GB/month
Function invocations150,000/month
Function memory2 GB RAM
ProjectsUnlimited
DeploymentsUnlimited

Troubleshooting

Build Fails with Database Error

Ensure DATABASE_URL is set correctly:

bunx vercel env ls

If the value looks wrong, remove and re-add it:

bunx vercel env rm DATABASE_URL production --yes
bunx vercel env add DATABASE_URL production

Git Author Permission Error

If you see "Git author must have access to the team":

  1. Go to Vercel Dashboard → Team Settings → Members
  2. Add your Git email address as a team member

Environment Variables Not Available

Environment variables set after a deployment require a redeploy:

bunx vercel --prod

On this page