From 9fb08b4ed77ac99533d74b3b315e8ba7e2f503d5 Mon Sep 17 00:00:00 2001 From: Kevin Veen-Birkenbach Date: Wed, 12 Aug 2026 19:45:10 +0200 Subject: [PATCH] fix(bookwyrm): stop the healthcheck sending a Host Django rejects BookWyrm 0 of run 31543714113 never converged, so Playwright never ran. The container log names the reason verbatim: "django.core.exceptions.DisallowedHost: Invalid HTTP_HOST header: bookwyrm. You may need to add bookwyrm to ALLOWED_HOSTS." The Host header is the bare entity name because container_hostname clamps to the 63 bytes sethostname(2) allows, and a v3 onion domain always exceeds that, so the lookup falls back from the primary domain to the entity name. The curl probe then reuses that kernel hostname as an HTTP Host, Django refuses it, the healthcheck fails and the container is killed every cycle. Pinning the probe to localhost decouples the Host header from the kernel hostname. It follows e9817f825, which fixed pretix the same way and recorded why this stays per-role: reusing a kernel hostname as an HTTP Host is the underlying design bug, but defaulting the curl flavor would change six roles at once. Co-Authored-By: Claude Opus 5 (1M context) --- roles/web-app-bookwyrm/meta/services.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/roles/web-app-bookwyrm/meta/services.yml b/roles/web-app-bookwyrm/meta/services.yml index 0738d64ea0..ff1a53520a 100644 --- a/roles/web-app-bookwyrm/meta/services.yml +++ b/roles/web-app-bookwyrm/meta/services.yml @@ -49,6 +49,7 @@ redis: bookwyrm: healthcheck: flavor: curl + hostname: localhost modes: compose: enabled: true