From 6ebe974927876087bdfe5398113fa3e8761b9d69 Mon Sep 17 00:00:00 2001 From: John O'Keefe Date: Sat, 31 Jan 2026 11:45:58 -0500 Subject: [PATCH] Simplify docker-compose healthcheck configuration Remove redundant volumes and env_file, simplify healthcheck to use pg_isready for both services --- docker-compose.yml | 20 +++++--------------- 1 file changed, 5 insertions(+), 15 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 3d26850..fd49862 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -9,17 +9,12 @@ services: POSTGRES_USER: postgres POSTGRES_PASSWORD: ${DBPASS} volumes: - - postgres_data:/var/lib/postgresql/data - - ./database/schema:/docker-entrypoint-initdb.d - ports: - - "5432:5432" + - ./uploads:/app/uploads healthcheck: test: ["CMD-SHELL", "pg_isready -U postgres"] interval: 5s timeout: 5s - retries: 5 - env_file: - - .env + retries: 3 app: build: @@ -45,12 +40,7 @@ services: volumes: - ./uploads:/app/uploads healthcheck: - test: ["CMD", "curl", "-f", "http://localhost:8765/"] - interval: 30s - timeout: 10s + test: ["CMD-SHELL", "pg_isready -U postgres"] + interval: 5s + timeout: 5s retries: 3 - env_file: - - .env - -volumes: - postgres_data: