[SHOT-247] fix: Disable proxy for container healthchecks - #8170
Conversation
BusyBox wget honours HTTP_PROXY/HTTPS_PROXY but does not implement NO_PROXY. Since #7858 switched the healthchecks from curl to wget on these Alpine images, deployments behind a forward proxy have their loopback probe routed through the proxy, marking containers unhealthy. Pass -Y off so the healthcheck always connects directly. BusyBox does not accept the GNU --no-proxy spelling, so -Y off is the portable form here.
🤖 Bitwarden Claude Code ReviewOverall Assessment: APPROVE This PR adds The two untouched healthchecks are correctly out of scope: Code Review DetailsNo blocking or non-blocking findings. The PR description documents the regression source, the BusyBox vs. GNU |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #8170 +/- ##
=========================================
+ Coverage 0 63.22% +63.22%
=========================================
Files 0 2381 +2381
Lines 0 103757 +103757
Branches 0 9385 +9385
=========================================
+ Hits 0 65603 +65603
- Misses 0 35925 +35925
- Partials 0 2229 +2229 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
🎟️ Tracking
https://bitwarden.atlassian.net/browse/SHOT-247
Regression from #7858 (SHOT-184), first shipped in 2026.7.x.
📔 Objective
Container healthchecks fail on self-hosted deployments behind a forward proxy.
The service images are Alpine-based, so
wgetresolves to BusyBox wget. BusyBox wget honoursHTTP_PROXY/HTTPS_PROXYbut does not implementNO_PROXYat all. When proxy variables are present in the container runtime environment (e.g. via the Docker clientconfig.jsonproxiesblock), the healthcheck's loopback probe is routed through the proxy and fails, marking the container unhealthy.curl, used before #7858, honouredNO_PROXY, so this worked prior to 2026.7.x.This adds
-Y offto every wget healthcheck so the loopback probe always connects directly, keeping the image-size/CVE benefit of having dropped curl.Reproduced and verified against both base images (BusyBox v1.37.0):
Note that BusyBox rejects the GNU
--no-proxyspelling (wget: unrecognized option: no-proxy), so-Y offis the portable form here.Covers all 13 wget healthcheck invocations across 12 Dockerfiles:
/alive— Api, Admin, Billing, Events, EventsProcessor, Notifications, Scim, Sso, Attachments/.well-known/openid-configuration/google.com/icon.pnghttps://localhost:8443primary and thehttp://localhost:8080fallbackOut of scope:
util/SeederApiis Debian-based with real curl, andutil/MsSqlusessqlcmd— neither is affected. Helm/k8s deployments are also unaffected, since kubelet performs the probing rather than the container.