fix: increase backend Docker healthcheck start_period to 3 minutes (refs #64)
All checks were successful
Deploy to Staging / Build Images (pull_request) Successful in 30s
Deploy to Staging / Deploy to Staging (pull_request) Successful in 31s
Deploy to Staging / Verify Staging (pull_request) Successful in 2m19s
Deploy to Staging / Notify Staging Ready (pull_request) Successful in 7s
Deploy to Staging / Notify Staging Failure (pull_request) Has been skipped

The CI was failing because Docker marked the backend unhealthy before the CI
wait loop completed. The backend needs time to run migrations and seed vehicle
data on startup.

Changes:
- start_period: 40s -> 180s (3 minutes)
- retries: 3 -> 5 (more tolerance)

Total time before unhealthy: 180s + (5 × 30s) = 5.5 minutes

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Eric Gullickson
2026-02-01 14:43:24 -06:00
parent 99fbf2bbb7
commit a31028401b

View File

@@ -140,8 +140,8 @@ services:
- node -e "require('http').get('http://localhost:3001/health', r => process.exit(r.statusCode===200?0:1)).on('error', () => process.exit(1))" - node -e "require('http').get('http://localhost:3001/health', r => process.exit(r.statusCode===200?0:1)).on('error', () => process.exit(1))"
interval: 30s interval: 30s
timeout: 10s timeout: 10s
retries: 3 retries: 5
start_period: 40s start_period: 180s
labels: labels:
- "traefik.enable=true" - "traefik.enable=true"
- "traefik.docker.network=motovaultpro_backend" - "traefik.docker.network=motovaultpro_backend"