fix: nginx waits for estore healthcheck before starting
Nginx resolves upstream hostnames at boot time; if estore isn't registered in Docker DNS yet it crashes in a restart loop. Using service_healthy lets nginx wait until the Next.js app passes its healthcheck before nginx attempts to start. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
57cc5840b9
commit
e2af78ff55
@ -9,8 +9,10 @@ services:
|
||||
volumes:
|
||||
- ./nginx/nginx.conf:/etc/nginx/nginx.conf:ro
|
||||
depends_on:
|
||||
- main-site
|
||||
- estore
|
||||
main-site:
|
||||
condition: service_started
|
||||
estore:
|
||||
condition: service_healthy
|
||||
restart: always
|
||||
|
||||
# ── Main website ─────────────────────────────────────────────────────────────
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user