From 119faf330dd46f87c3ef9a5cdae4993cd851797b Mon Sep 17 00:00:00 2001 From: msramalho <19508417+msramalho@users.noreply.github.com> Date: Wed, 12 Feb 2025 10:18:03 +0000 Subject: [PATCH] fixing healthchecks --- docker-compose.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 723f225..2b59517 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -22,7 +22,7 @@ services: depends_on: - redis healthcheck: - test: ["CMD", "curl", "-f", "http://localhost:8000/health"] + test: ["CMD", "python3", "-c", 'import sys, urllib.request; sys.exit(urllib.request.urlopen("http://localhost:8000/health").getcode() != 200)'] interval: 30s timeout: 10s retries: 3 @@ -49,7 +49,7 @@ services: - web - redis healthcheck: - test: ["CMD", "pipenv", "run", "celery", "-A", "worker.main.celery", "status"] + test: ["CMD-SHELL", "./poetry-venv/bin/poetry run celery -A app.worker.main.celery inspect ping || exit 1"] interval: 30s timeout: 10s retries: 3