Robustness: Add json-file log rotation limits to all docker services

This commit is contained in:
2026-06-07 09:26:39 +02:00
parent 8805044bb6
commit e7b5ea9a61
3 changed files with 471 additions and 0 deletions

View File

@@ -26,6 +26,11 @@ services:
- "5432:5432"
networks:
- translate-network
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER:-translate} -d ${POSTGRES_DB:-translate_db}"]
interval: 5s
@@ -47,6 +52,11 @@ services:
- "6379:6379"
networks:
- translate-network
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 5s
@@ -84,6 +94,11 @@ services:
- "8000:8000"
networks:
- translate-network
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
depends_on:
postgres:
condition: service_healthy
@@ -119,6 +134,11 @@ services:
- "${FRONTEND_PORT:-3010}:3000"
networks:
- translate-network
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
depends_on:
backend:
condition: service_healthy
@@ -144,6 +164,11 @@ services:
- nginx_cache:/var/cache/nginx
networks:
- translate-network
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
depends_on:
backend:
condition: service_healthy