feat: add privacy-safe server diagnostics

This commit is contained in:
inman committed 2026-08-30 16:01:42 +08:00
1 parent 2360506607
commit a3963ad0f6
27 files changed
+1305 -112

No files matched your search

+9
View File
@@ -1,3 +1,9 @@
x-default-logging: &default-logging
driver: json-file
options:
max-size: "${LOG_MAX_SIZE:-20m}"
max-file: "${LOG_MAX_FILES:-10}"
services:
postgres:
profiles: ["local"]
@@ -9,6 +15,7 @@ services:
POSTGRES_PASSWORD: ${LOCAL_POSTGRES_PASSWORD:-local-dev-only-change-me}
volumes:
- ltjt-postgres:/var/lib/postgresql/data
logging: *default-logging
healthcheck:
test: ["CMD-SHELL", "pg_isready -U $${POSTGRES_USER} -d $${POSTGRES_DB}"]
interval: 10s
@@ -23,6 +30,7 @@ services:
environment:
DATABASE_URL: ${DATABASE_URL:?set DATABASE_URL in .env.production}
command: ["sh", "-c", "node .build/control-plane/src/migrate.js && node .build/control-plane/src/server.js"]
logging: *default-logging
healthcheck:
test: ["CMD", "node", "-e", "fetch('http://127.0.0.1:8786/health/ready').then(r=>process.exit(r.ok?0:1)).catch(()=>process.exit(1))"]
interval: 15s
@@ -44,6 +52,7 @@ services:
- ./infra/Caddyfile:/etc/caddy/Caddyfile:ro
- caddy-data:/data
- caddy-config:/config
logging: *default-logging
volumes:
ltjt-postgres: