Cybersecurity-Projects/PROJECTS/advanced/bug-bounty-platform/.env.example

110 lines
4.2 KiB
Plaintext

# =============================================================================
# AngelaMos | 2026
# .env.example
# =============================================================================
# Copy this file to .env and update values for your environment
# =============================================================================
# =============================================================================
# HOST PORTS (change these to avoid conflicts between projects)
# =============================================================================
NGINX_HOST_PORT=8420
BACKEND_HOST_PORT=5420
FRONTEND_HOST_PORT=3420
POSTGRES_HOST_PORT=4420
REDIS_HOST_PORT=6420
# =============================================================================
# Application
# =============================================================================
APP_NAME=FullStack-Template
ENVIRONMENT=development
DEBUG=true
LOG_LEVEL=INFO
LOG_JSON_FORMAT=false
# =============================================================================
# Server (internal container settings)
# =============================================================================
HOST=0.0.0.0
PORT=8000
RELOAD=true
# =============================================================================
# PostgreSQL
# =============================================================================
POSTGRES_USER=postgres
POSTGRES_PASSWORD=postgres
POSTGRES_DB=app_db
POSTGRES_HOST=db
POSTGRES_CONTAINER_PORT=5432
DATABASE_URL=postgresql+asyncpg://${POSTGRES_USER}:${POSTGRES_PASSWORD}@${POSTGRES_HOST}:${POSTGRES_CONTAINER_PORT}/${POSTGRES_DB}
DB_POOL_SIZE=20
DB_MAX_OVERFLOW=10
DB_POOL_TIMEOUT=30
DB_POOL_RECYCLE=1800
# =============================================================================
# Redis
# =============================================================================
REDIS_HOST=redis
REDIS_CONTAINER_PORT=6379
REDIS_PASSWORD=
REDIS_URL=redis://${REDIS_HOST}:${REDIS_CONTAINER_PORT}
# =============================================================================
# Security / JWT
# =============================================================================
SECRET_KEY=dev-only-change-this-in-production-minimum-32-characters-long
JWT_ALGORITHM=HS256
ACCESS_TOKEN_EXPIRE_MINUTES=15
REFRESH_TOKEN_EXPIRE_DAYS=7
# =============================================================================
# Admin Bootstrap (optional)
# =============================================================================
# If set, registering with this email auto-promotes to admin role.
# Leave empty or remove to disable auto-admin (all users register as USER).
ADMIN_EMAIL=
# =============================================================================
# CORS
# =============================================================================
# Use ["*"] to allow all origins (public API)
# Or specify origins: ["http://localhost:8420","http://localhost:3420"]
CORS_ORIGINS=["*"]
# =============================================================================
# Rate Limiting
# =============================================================================
RATE_LIMIT_DEFAULT=100/minute
RATE_LIMIT_AUTH=20/minute
# =============================================================================
# Frontend (Vite)
# =============================================================================
VITE_API_URL=/api
VITE_API_TARGET=http://localhost:8000
VITE_APP_TITLE=My App
# =============================================================================
# Cloudflare Tunnel (Production only - or use whatever deployment method you want)
# =============================================================================
# Option 1: Cloudflare Tunnel (zero config, no port forwarding needed)
# - Get token from Cloudflare Zero Trust dashboard
# - Access > Tunnels > Create a tunnel > Name it > Copy token below
# - Configure public hostname: yourdomain.com -> http://nginx:80
#
# Option 2: Traditional hosting (VM + domain + DNS)
# - Host on a VM, buy a domain, create A/CNAME record in Cloudflare DNS
# - Point to your VM's IP, expose nginx port, configure reverse proxy/SSL
#
# Option 3: Whatever works for you
# - Just make sure your nginx container is accessible and SSL is configured
CLOUDFLARE_TUNNEL_TOKEN=