Spaces:
Running
Running
File size: 1,959 Bytes
2df0cf9 | 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 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 | # Environment Variables Template
# Copy this file to .env and fill in your values
# Application
APP_NAME={{ config.projectName or 'myapp' }}
APP_ENV={{ config.mode or 'production' }}
APP_PORT={{ config.appPort or '3000' }}
APP_URL=http://localhost:{{ config.appPort or '3000' }}
{% if config.services.database == 'postgresql' %}
# PostgreSQL Database
POSTGRES_HOST=postgres
POSTGRES_PORT=5432
POSTGRES_USER=postgres
POSTGRES_PASSWORD=changeme_secure_password
POSTGRES_DB={{ config.projectName or 'myapp' }}
DATABASE_URL=postgresql://postgres:changeme_secure_password@postgres:5432/{{ config.projectName or 'myapp' }}
{% endif %}
{% if config.services.database == 'mysql' %}
# MySQL Database
MYSQL_HOST=mysql
MYSQL_PORT=3306
MYSQL_ROOT_PASSWORD=changeme_root_password
MYSQL_DATABASE={{ config.projectName or 'myapp' }}
MYSQL_USER=user
MYSQL_PASSWORD=changeme_secure_password
DATABASE_URL=mysql://user:changeme_secure_password@mysql:3306/{{ config.projectName or 'myapp' }}
{% endif %}
{% if config.services.database == 'mongodb' %}
# MongoDB Database
MONGO_HOST=mongodb
MONGO_PORT=27017
MONGO_USERNAME=admin
MONGO_PASSWORD=changeme_secure_password
MONGO_DATABASE={{ config.projectName or 'myapp' }}
MONGO_URL=mongodb://admin:changeme_secure_password@mongodb:27017/{{ config.projectName or 'myapp' }}?authSource=admin
{% endif %}
{% if config.services.redis %}
# Redis
REDIS_HOST=redis
REDIS_PORT=6379
REDIS_URL=redis://redis:6379
{% endif %}
{% if config.services.nginx %}
# Nginx
NGINX_PORT={{ config.nginxPort or '80' }}
{% if config.ssl %}
NGINX_SSL_PORT=443
{% endif %}
{% endif %}
# Security (Change these!)
SECRET_KEY=changeme_random_secret_key_here
JWT_SECRET=changeme_jwt_secret_here
SESSION_SECRET=changeme_session_secret_here
# Logging
LOG_LEVEL={{ 'debug' if config.mode == 'development' else 'info' }}
{% if config.mode == 'development' %}
# Development Only
DEBUG=true
HOT_RELOAD=true
{% else %}
# Production Only
DEBUG=false
{% endif %}
|