add healthcheck to backend service with 10s interval and 5 retries

This commit is contained in:
Egor Pozharov
2026-04-16 15:16:17 +06:00
parent 76668f8a48
commit 6864235e3d

View File

@@ -23,6 +23,12 @@ services:
JWT_SECRET: ${JWT_SECRET}
SEED_ADMIN_PASSWORD: ${SEED_ADMIN_PASSWORD}
# Нет expose - backend доступен только внутри сети delivery-network
healthcheck:
test: ["CMD-SHELL", "wget -qO- http://localhost:8080/health || exit 1"]
interval: 10s
timeout: 5s
retries: 5
depends_on:
postgres:
condition: service_healthy