-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathenv.vercel.example
More file actions
48 lines (35 loc) · 1.54 KB
/
env.vercel.example
File metadata and controls
48 lines (35 loc) · 1.54 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
# Vercel Environment Variables Template
# Copy these to your Vercel Project Settings → Environment Variables
# ===== REQUIRED =====
# Database
MONGODB_URI=mongodb+srv://username:password@cluster.mongodb.net/dbname?retryWrites=true&w=majority
# JWT Secrets (Generate secure random strings)
JWT_SECRET=your-super-secret-jwt-key-minimum-32-characters-long
JWT_REFRESH_SECRET=your-super-secret-refresh-key-minimum-32-characters-long
# Frontend URL (comma-separated, no spaces)
FRONTEND_URL=https://your-frontend.vercel.app,https://yourdomain.com
# Vercel Blob Storage (Get from Vercel Dashboard → Storage → Blob)
BLOB_READ_WRITE_TOKEN=vercel_blob_rw_xxxxxxxxxxxx
# ===== EMAIL SERVICE (Choose one method) =====
# Method 1: Gmail
EMAIL_SERVICE=gmail
EMAIL_USER=your-email@gmail.com
EMAIL_PASSWORD=your-16-char-app-password
EMAIL_FROM=L2H Blog <your-email@gmail.com>
# Method 2: Mailgun (Alternative)
# EMAIL_SERVICE=mailgun
# MAILGUN_API_KEY=your-mailgun-api-key
# MAILGUN_DOMAIN=mg.yourdomain.com
# EMAIL_FROM=L2H Blog <noreply@yourdomain.com>
# ===== OPTIONAL =====
# Rate Limiting
RATE_LIMIT_WINDOW_MS=900000
RATE_LIMIT_MAX_REQUESTS=100
# Node Environment (auto-set by Vercel, but can override)
NODE_ENV=production
# ===== NOTES =====
# 1. Never commit the actual .env file with real values
# 2. Set these in Vercel Dashboard → Settings → Environment Variables
# 3. Apply to all environments: Production, Preview, Development
# 4. After adding/changing env vars, redeploy your project
# 5. MongoDB Atlas: Allow access from anywhere (0.0.0.0/0) for Vercel