From b731c9cd24a1be35d7ec4a17d043a4ee04132ae0 Mon Sep 17 00:00:00 2001 From: Eric Liu Date: Sun, 27 Jul 2025 08:14:36 -0700 Subject: [PATCH] fix llm heath check failure --- compose.yaml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/compose.yaml b/compose.yaml index c328474..b4a99a9 100644 --- a/compose.yaml +++ b/compose.yaml @@ -59,7 +59,15 @@ services: environment: - OPENAI_API_KEY=${OPENAI_API_KEY} healthcheck: - test: ["CMD", "curl", "-f", "http://localhost/health"] + test: + - CMD + - python3 + - -c + - import sys, urllib.request; sys.exit(0 if urllib.request.urlopen('http://localhost/health').getcode() == 200 else 1) + interval: 10s + timeout: 5s + retries: 3 + start_period: 60s discord-bot: restart: unless-stopped