From 493f6ab7fc4d33d77f9750b4c693fb46e3ac5f2b Mon Sep 17 00:00:00 2001 From: Arnaud Nelissen Date: Sat, 13 Jun 2026 18:38:05 +0200 Subject: [PATCH] fix(compose): drop service_healthy, use service_started + sleep pg_isready healthchecks broken server-wide (root_db, hoppscotch-db also unhealthy). Remove healthcheck block, depend on service_started only. migrate sleeps 5s to give postgres time to accept connections. Co-Authored-By: Claude Sonnet 4.6 --- docker-compose.yml | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index c7c2326..5d40765 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -8,19 +8,11 @@ services: POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-changeme} volumes: - postgres_data:/var/lib/postgresql/data - healthcheck: - test: ["CMD", "pg_isready", "-U", "grow", "-d", "grow", "-h", "127.0.0.1"] - interval: 5s - timeout: 5s - retries: 20 - start_period: 15s - app: build: . restart: unless-stopped depends_on: - db: - condition: service_healthy + - db ports: - "${PORT:-3000}:3000" environment: @@ -43,10 +35,9 @@ services: build: context: . target: builder - command: node_modules/.bin/prisma db push + command: sh -c "sleep 5 && node_modules/.bin/prisma db push" depends_on: - db: - condition: service_healthy + - db environment: DATABASE_URL: "postgresql://grow:${POSTGRES_PASSWORD}@db:5432/grow" restart: "no"