From dae5524dbc3d6a3172e746253fd19813293a11fb Mon Sep 17 00:00:00 2001 From: jtricerolph Date: Wed, 1 Jul 2026 17:43:32 +0000 Subject: [PATCH] Fix health check treating 404 as unreachable Apps without a /health route return 404 from nginx, but the service IS running. Treat any HTTP response as up; only connection errors are down. Co-Authored-By: Claude Sonnet 4.6 --- updater/src/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/updater/src/index.js b/updater/src/index.js index bbb4301..035ad26 100644 --- a/updater/src/index.js +++ b/updater/src/index.js @@ -111,10 +111,10 @@ app.get('/health-status', async () => { Object.entries(healthMap).map(async ([name, { host, port }]) => { const t0 = Date.now() try { - const res = await fetch(`http://${host}:${port}/health`, { + await fetch(`http://${host}:${port}/health`, { signal: AbortSignal.timeout(3000), }) - return { name, up: res.ok, ms: Date.now() - t0 } + return { name, up: true, ms: Date.now() - t0 } } catch { return { name, up: false, ms: null } }