add Docker Compose configuration for Traefik and MySQL, update environment variables
All checks were successful
Build & Publish Docker Image / build-and-push (push) Successful in 44s
All checks were successful
Build & Publish Docker Image / build-and-push (push) Successful in 44s
This commit is contained in:
22
.env.example
22
.env.example
@@ -1,24 +1,34 @@
|
||||
# Server Settings
|
||||
PORT=8080
|
||||
|
||||
# DB Settings
|
||||
# Infrastruttura Docker (Traefik + MySQL)
|
||||
API_DOMAIN=api.esempio.com
|
||||
ACME_EMAIL=tua@email.com
|
||||
MYSQL_ROOT_PASSWORD=password-sicura
|
||||
|
||||
# DB Settings (usato per sviluppo locale; in Docker il DSN è costruito dal compose)
|
||||
DB_DSN=root:secret@tcp(127.0.0.1:3306)/emly?parseTime=true&loc=UTC
|
||||
MAX_OPEN_CONNS=25
|
||||
MAX_IDLE_CONNS=5
|
||||
CONN_MAX_LIFETIME=5m
|
||||
DB_MAX_OPEN_CONNS=25
|
||||
DB_MAX_IDLE_CONNS=5
|
||||
DB_CONN_MAX_LIFETIME=5
|
||||
DATABASE_NAME=emly
|
||||
|
||||
# API Keys
|
||||
API_KEY=key-one
|
||||
ADMIN_KEY=admin-key-one
|
||||
|
||||
# Rate Limiting (unauthenticated: no X-API-Key / X-Admin-Key)
|
||||
# Rate Limiting — Traefik edge (condiviso tra repliche)
|
||||
TRAEFIK_RL_AVERAGE=30
|
||||
TRAEFIK_RL_BURST=10
|
||||
TRAEFIK_RL_PERIOD=1m
|
||||
|
||||
# Rate Limiting — App (unauthenticated: no X-API-Key / X-Admin-Key)
|
||||
RL_UNAUTH_MAX_REQS=10
|
||||
RL_UNAUTH_WINDOW=5m
|
||||
RL_UNAUTH_MAX_FAILS=5
|
||||
RL_UNAUTH_BAN_DUR=15m
|
||||
|
||||
# Rate Limiting (authenticated: X-API-Key or X-Admin-Key present)
|
||||
# Rate Limiting — App (authenticated: X-API-Key or X-Admin-Key present)
|
||||
RL_AUTH_MAX_REQS=100
|
||||
RL_AUTH_WINDOW=1m
|
||||
RL_AUTH_MAX_FAILS=20
|
||||
|
||||
Reference in New Issue
Block a user