Fix nginx/newt boot race by raising API healthcheck start_period to 120s

On a fresh install, the api container's docker-entrypoint.sh does
migrations + seed + MaxMind GeoLite2 download synchronously before
binding port 4000, which routinely exceeds the previous 75s tolerance
(start_period 30s + 3x15s retries). When the API flipped to unhealthy,
nginx and newt (which depend on api: condition: service_healthy)
aborted, leaving the tunnel offline and requiring a manual
'docker compose up -d nginx newt' second pass.

Bumping start_period to 120s gives first-boot enough slack, matches
convention (Rocket.Chat 90s, Gancio 60s), and leaves steady-state
restarts unaffected. Change applied to both dev (docker-compose.yml)
and prod (docker-compose.prod.yml) since the release tarball ships
the latter.

Bunker Admin
This commit is contained in:
bunker-admin 2026-04-15 10:05:20 -06:00
parent e55bc07eb6
commit 5115c65691
2 changed files with 2 additions and 2 deletions

View File

@ -30,7 +30,7 @@ services:
interval: 15s
timeout: 5s
retries: 3
start_period: 30s
start_period: 120s
environment:
- NODE_ENV=${NODE_ENV:-production}
- PORT=4000

View File

@ -29,7 +29,7 @@ services:
interval: 15s
timeout: 5s
retries: 3
start_period: 30s
start_period: 120s
environment:
- NODE_ENV=${NODE_ENV:-development}
- PORT=4000