From 0a78491587a4e32c2cc247a1ea3d329dd778c177 Mon Sep 17 00:00:00 2001 From: Christian van Dijk Date: Mon, 23 Feb 2026 23:17:18 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=94=A7=20update=20docker-compose=20config?= =?UTF-8?q?uration=20to=20include=20'handheld-net'=20network=20and=20modif?= =?UTF-8?q?y=20healthcheck=20settings=20for=20services?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docker-compose.yml | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index f6a6772..1990665 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -4,6 +4,8 @@ services: context: ./devices-api dockerfile: Dockerfile container_name: handheld-api + networks: + - handheld-net ports: - "8080:8080" volumes: @@ -24,15 +26,17 @@ services: - REDIS_HOST=redis - REDIS_PORT=6379 healthcheck: - test: ["CMD-SHELL", "wget -q -O - http://localhost:8080/health/ready || exit 1"] - interval: 10s + test: ["CMD-SHELL", "wget -q -O - http://localhost:8080/health/live || exit 1"] + interval: 5s timeout: 5s - retries: 3 - start_period: 10s + retries: 10 + start_period: 30s postgres: image: postgres:15-alpine container_name: handheld-postgres + networks: + - handheld-net ports: - "5432:5432" environment: @@ -51,6 +55,8 @@ services: redis: image: redis:7-alpine container_name: handheld-redis + networks: + - handheld-net ports: - "6379:6379" healthcheck: @@ -64,6 +70,8 @@ services: context: ./frontend dockerfile: Dockerfile container_name: handheld-frontend + networks: + - handheld-net ports: - "8090:8090" env_file: @@ -85,6 +93,8 @@ services: context: ./devices-worker dockerfile: Dockerfile container_name: handheld-worker + networks: + - handheld-net volumes: - ./devices-worker:/app env_file: @@ -107,3 +117,7 @@ services: interval: 10s timeout: 3s retries: 3 + +networks: + handheld-net: + name: handheld-devices