From 33b24114c0f55226c0cefcae808f286c567b2a57 Mon Sep 17 00:00:00 2001 From: Kaindl Network <82705244+kaindlnetwork@users.noreply.github.com> Date: Mon, 24 Jun 2024 14:58:01 +0200 Subject: [PATCH] Update docker-compose.yml Melisearch is a dependency for the frontend but isn't configured to be a healthy service before starting the web container. Melisearch lacks a health check to ensure it operates as expected. Without a health check, it could run endlessly or restart without functioning properly. Additionally, the web container lacks a defined timezone to output correct timestamps for debugging purposes. --- docker-compose.yml | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 6f8eecd..d7d8bde 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -5,6 +5,15 @@ services: MEILI_MASTER_KEY: "Moin" # Change this to a secure value volumes: - "meilisearch-data:/meili_data" + healthcheck: + test: + - CMD + - wget + - '--no-verbose' + - '--spider' + - 'http://localhost:7700/health' + retries: 3 + timeout: 5s web: build: . @@ -15,9 +24,10 @@ services: environment: MEILI_HOST: "http://meilisearch:7700" MEILI_KEY: "Moin" # Change this to a secure value + TZ: "Europe/Berlin" depends_on: - - "meilisearch" - + meilisearch: + condition: service_healthy volumes: meilisearch-data: sqlite-data: