From 27091946138d2b2d7d2d9e19a4391af10c9d6426 Mon Sep 17 00:00:00 2001 From: oscgonfer Date: Fri, 1 Nov 2024 15:39:49 +0100 Subject: [PATCH] Add healthcheck on web to restart based on curl --- compose/web.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/compose/web.yml b/compose/web.yml index a3857300..8eea0103 100644 --- a/compose/web.yml +++ b/compose/web.yml @@ -5,6 +5,11 @@ services: app: condition: service_healthy restart: true + healthcheck: + test: ["CMD-SHELL", "curl http://app:3000"] + timeout: 10s + start-period: 5s + restart: always ports: - 80:80 - 80:80/udp