-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.env.production.example
More file actions
55 lines (39 loc) · 2.05 KB
/
.env.production.example
File metadata and controls
55 lines (39 loc) · 2.05 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
48
49
50
51
52
53
54
55
# =============================================================
# API-Watch — Production Environment Variables
# Copy this file: cp .env.production.example .env.production
# Fill in values and NEVER commit .env.production to git
# =============================================================
# ── Required ─────────────────────────────────────────────────
# PostgreSQL connection (matches docker-compose.prod.yml services)
DATABASE_URL=postgresql+asyncpg://apiwatch:CHANGE_ME_STRONG_PASSWORD@postgres:5432/apiwatch
POSTGRES_USER=apiwatch
POSTGRES_PASSWORD=CHANGE_ME_STRONG_PASSWORD
POSTGRES_DB=apiwatch
# JWT secret — generate with: openssl rand -hex 32
JWT_SECRET_KEY=CHANGE_ME_GENERATE_WITH_OPENSSL
# Redis connection (matches docker-compose.prod.yml services)
REDIS_URL=redis://redis:6379/0
# ── Recommended ──────────────────────────────────────────────
# CORS — set to your production domain
CORS_ALLOWED_ORIGINS=https://your-domain.com
# Server
PORT=8000
LOG_LEVEL=INFO
DEBUG=false
# Gunicorn workers — recommended: (2 × CPU cores) + 1
GUNICORN_WORKERS=2
GUNICORN_TIMEOUT=120
# ── Database Pool ────────────────────────────────────────────
DB_POOL_SIZE=10
DB_MAX_OVERFLOW=20
DB_POOL_TIMEOUT=30
# ── Rate Limiting ────────────────────────────────────────────
RATE_LIMIT_ENABLED=true
RATE_LIMIT_DEFAULT=100
RATE_LIMIT_AUTH=5
RATE_LIMIT_WINDOW=60
# ── Auth Tokens ──────────────────────────────────────────────
ACCESS_TOKEN_EXPIRE_MINUTES=30
REFRESH_TOKEN_EXPIRE_DAYS=7
# ── Frontend Build Arg (used during docker build only) ───────
VITE_API_URL=https://your-domain.com