This commit is contained in:
Grbisba
2026-11-07 10:41:21 +03:00
parent 4c066ff191
commit 1e0d18e25b
306 changed files with 14036 additions and 627 deletions
+11 -60
View File
@@ -1,63 +1,14 @@
# Choose credentials locally. File paths contain no secret values.
DATABASE_URL_FILE=/run/secrets/database_url
# Optional on 3, required use on 4 in lab2; Redis OR Valkey:
SESSION_STORE=postgres
CACHE_URL_FILE=/run/secrets/cache_url
API_REPLICAS=2
IDEMPOTENCY_TTL_SECONDS=86400
# 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
# scripts/bootstrap.sh creates ignored .env.lab3 with random synthetic credentials.
# This example documents actual Compose inputs; it contains no live secrets.
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
HOST_PORT=18080
API_REPLICAS=2
API_CPUS=1
API_MEMORY=512m
POSTGRES_MAX_CONNECTIONS=8
APPLICATION_LOG_LEVEL=warn
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
API_IMAGE=mtusi-messenger:lab3
# Session TTL defaults to 3600; use >=300 for smoke/persistence.
# Message idempotency retention is fixed at 24 hours; API never runs migrations.