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