cosmo/.env.production

56 lines
1.7 KiB
Plaintext
Raw Normal View History

2025-12-02 13:25:28 +00:00
# Cosmo Production Environment Configuration
# ======================
# Database Configuration
# ======================
DATABASE_NAME=cosmo_db
DATABASE_USER=postgres
2025-12-02 15:14:01 +00:00
DATABASE_PASSWORD=cosmo
2025-12-02 13:25:28 +00:00
DATABASE_POOL_SIZE=20
DATABASE_MAX_OVERFLOW=10
# ======================
# Redis Configuration
# ======================
2025-12-02 15:14:01 +00:00
REDIS_PASSWORD=cosmo
2025-12-02 13:25:28 +00:00
REDIS_MAX_CONNECTIONS=50
# ======================
# Application Configuration
# ======================
2025-12-02 14:50:18 +00:00
# CORS - Support both internal IP access and external domain
# Format: comma-separated list of origins
# Examples:
# - Internal IP only: CORS_ORIGINS=http://192.168.1.100
# - Domain only: CORS_ORIGINS=http://your-domain.com,https://your-domain.com
# - Both IP and domain: CORS_ORIGINS=http://192.168.1.100,http://your-domain.com,https://your-domain.com
# - Allow all (development): CORS_ORIGINS=*
CORS_ORIGINS=*
2025-12-02 13:25:28 +00:00
# API Base URL for frontend
2025-12-02 14:54:54 +00:00
# 推荐:留空或注释掉,让前端使用相对路径 /api通过 Nginx 反向代理)
# 这样可以同时支持内网 IP 和外网域名访问
# VITE_API_BASE_URL=
# 如果前后端分离部署在不同服务器,才需要设置完整的 API 地址:
# VITE_API_BASE_URL=http://your-domain.com/api
2025-12-02 13:25:28 +00:00
# ======================
# Cache Configuration
# ======================
CACHE_TTL_DAYS=3
# ======================
# Upload Configuration
# ======================
MAX_UPLOAD_SIZE=10485760
# ======================
# Data Path Configuration
# ======================
# All data will be stored under /opt/cosmo/data/
# - /opt/cosmo/data/postgres - Database files
# - /opt/cosmo/data/redis - Redis persistence
# - /opt/cosmo/data/upload - User uploaded files
# - /opt/cosmo/data/logs - Application logs