forked from mtusi2026/mtusi2026lab2
56 lines
1.6 KiB
Bash
56 lines
1.6 KiB
Bash
# Copy to .env and replace both password placeholders for a local synthetic stand.
|
|
# Never commit .env. Existing .env files must be updated manually; see REPORT.md.
|
|
HOST_PORT=8080
|
|
|
|
APP_ENABLED=true
|
|
APP_HOST=0.0.0.0
|
|
APP_PORT=8080
|
|
APP_READ_TIMEOUT=5s
|
|
APP_WRITE_TIMEOUT=10s
|
|
APP_IDLE_TIMEOUT=60s
|
|
APP_SHUTDOWN_TIMEOUT=8s
|
|
|
|
APPLICATION_LOG_LEVEL=info
|
|
APPLICATION_ENVIRONMENT=dev
|
|
APPLICATION_SHUTDOWN_TIMEOUT=8s
|
|
APPLICATION_REQUEST_RATE_LIMIT=100
|
|
APPLICATION_BURST_RATE_LIMIT=100
|
|
APPLICATION_RATE_LIMIT_TTL=1m
|
|
|
|
# Container addresses and ports for the Compose network.
|
|
# These ports are not published on the host.
|
|
POSTGRES_HOST=postgres
|
|
POSTGRES_PORT=5432
|
|
POSTGRES_USER=messenger
|
|
POSTGRES_PASSWORD=replace-with-local-postgres-password
|
|
POSTGRES_DATABASE=messenger
|
|
POSTGRES_VERSION_TABLE=versions
|
|
# Tern applies embedded migrations at API startup.
|
|
POSTGRES_RUN_MIGRATIONS=true
|
|
POSTGRES_MAX_CONNECTIONS=10
|
|
POSTGRES_CONNECT_TIMEOUT=500ms
|
|
POSTGRES_QUERY_TIMEOUT=2s
|
|
|
|
REDIS_HOST=redis
|
|
REDIS_PORT=6379
|
|
REDIS_USERNAME=default
|
|
REDIS_PASSWORD=replace-with-local-redis-password
|
|
REDIS_DB=0
|
|
|
|
SESSION_TTL_SECONDS=3600
|
|
JWT_ACCESS_TOKEN_LIFETIME=15m
|
|
# Legacy fallback used only when SESSION_TTL_SECONDS is empty.
|
|
JWT_REFRESH_TOKEN_LIFETIME=24h
|
|
# Container paths. Compose mounts ./certs read-only at /run/certs.
|
|
JWT_PUBLIC_KEY_PATH=/run/certs/public_key.pem
|
|
JWT_PRIVATE_KEY_PATH=/run/certs/private_key.pem
|
|
|
|
# Local HTTP defaults. Use secure cookies when serving through HTTPS.
|
|
COOKIES_ENABLED=false
|
|
COOKIES_DOMAIN=localhost
|
|
COOKIES_PATH=/
|
|
COOKIES_SECURE=false
|
|
COOKIES_SAME_SITE=lax
|
|
# Viper accepts a whitespace-separated list of origins.
|
|
COOKIES_ALLOWED_ORIGINS=http://localhost:8080
|