From 566f02a3f4fdd26d4f6aa7ef451e7a27114e7a85 Mon Sep 17 00:00:00 2001 From: Lukas Remis Date: Thu, 17 Sep 2026 20:57:28 +0200 Subject: [PATCH] Deploy: the rspamd healthcheck probed with a tool the image does not have MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `wget -qO- .../ping | grep -qi pong` exits 127 forever: the rspamd image ships neither wget nor curl. The container therefore reported "unhealthy" from the moment it started while answering /ping perfectly — and `webmail.sh up` waits on health, so a working engine failed the bring-up. `rspamc stat` instead, which ships with the engine and needs no password from inside the container. Worth noting what this did NOT break: nothing declares depends_on: rspamd and the health gate deliberately ignores it, so mail kept flowing throughout. The cost was a bring-up that looked failed and an alarming status in the UI. Co-Authored-By: Claude Opus 5 Claude-Session: https://claude.ai/code/session_018SqJYt7jD7oUEkoY68sBZo --- docker-compose.yml | 5 ++++- docker/docker-compose.yml | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index b694b47..7da75c3 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -241,7 +241,10 @@ services: - ./docker/rspamd/local.d:/etc/rspamd/local.d:ro - ${DATA_ROOT:-/NO-.env-FOUND-RUN-deploy_webmail.sh-init-FIRST}/rspamd:/var/lib/rspamd healthcheck: - test: ["CMD-SHELL", "wget -qO- http://127.0.0.1:11334/ping | grep -qi pong"] + # rspamc, not wget/curl: the rspamd image ships neither, so the obvious + # HTTP probe fails 127 forever and the container sits "unhealthy" while + # the engine is answering perfectly. + test: ["CMD-SHELL", "rspamc stat > /dev/null 2>&1"] interval: 30s timeout: 5s retries: 5 diff --git a/docker/docker-compose.yml b/docker/docker-compose.yml index d73315d..1b482e3 100644 --- a/docker/docker-compose.yml +++ b/docker/docker-compose.yml @@ -92,7 +92,10 @@ services: - "127.0.0.1:11333:11333" # scan worker (/checkv2) - "127.0.0.1:11334:11334" # controller (/learnspam, /stat) healthcheck: - test: ["CMD-SHELL", "wget -qO- http://127.0.0.1:11334/ping | grep -qi pong"] + # rspamc, not wget/curl: the rspamd image ships neither, so the obvious + # HTTP probe fails 127 forever and the container sits "unhealthy" while + # the engine is answering perfectly. + test: ["CMD-SHELL", "rspamc stat > /dev/null 2>&1"] interval: 10s timeout: 5s retries: 12