From da6339d74d1744131f35f9bb0d530822730b16b3 Mon Sep 17 00:00:00 2001
From: Bart van der Braak <bart@vanderbraak.nl>
Date: Tue, 19 Nov 2024 20:04:14 +0100
Subject: [PATCH] Fix healthchecks and volumes

---
 docker-compose.yml | 13 ++++++++++++-
 1 file changed, 12 insertions(+), 1 deletion(-)

diff --git a/docker-compose.yml b/docker-compose.yml
index 87d0094..3db7be5 100644
--- a/docker-compose.yml
+++ b/docker-compose.yml
@@ -18,7 +18,7 @@ services:
         - CMD
         - curl
         - '-f'
-        - 'http://127.0.0.1:8010'
+        - 'http://localhost:$${BUILDBOT_WEB_PORT}'
       interval: 2s
       timeout: 10s
       retries: 15
@@ -50,3 +50,14 @@ services:
       - 'WORKERNAME=${WORKERNAME:-example-worker}'
       - 'WORKERPASS=${WORKERPASS:-pass}'
       - 'WORKER_ENVIRONMENT_BLACKLIST=${WORKER_ENVIRONMENT_BLACKLIST:-DOCKER_BUILDBOT* BUILDBOT_ENV_* BUILDBOT_1* WORKER_ENVIRONMENT_BLACKLIST}'
+    healthcheck:
+      test:
+        - CMD
+        - curl
+        - '-f'
+        - 'http://$${BUILDMASTER}:$${BUILDMASTER_PORT}'
+      interval: 5s
+      timeout: 20s
+      retries: 10
+volumes:
+  buildbot-db: {}
\ No newline at end of file