"""libredesk — health check: the app's /health endpoint responds 200 through Traefik. This is the same endpoint the compose healthcheck hits internally (:9000/health); exercising it via the public domain confirms the app is bound and the proxy route is wired. """ from __future__ import annotations import os import sys sys.path.insert(0, os.path.join(os.path.dirname(__file__), "..", "..", "..", "runner")) from harness import http as harness_http # noqa: E402 def test_libredesk_health(live_app): """GET /health → 200.""" url = f"https://{live_app}/health" status, _ = harness_http.retry_http_get(url, expect_status=(200,), max_wait=120, interval=5) assert status == 200, f"GET {url} HTTP {status} (expected 200)"