I think the busybox wget ignores the no_proxy variable and send every request to the proxy if configured. It would also send the request the request to the proxy when host → localhost
For the application SonarQube we set these variables in the helm chart
sonarProperties
http.proxyHost: proxy.example.com
http.proxyPort: 3128
https.proxyHost: proxy.example.com
https.proxyPort: 3128
http.nonProxyHosts: localhost|127.*|[::1]||<some_internal_domains
We use the PodPreset tool from the RedHat CoP which mounts a config map of proxy variables in each pod.
Environment variables:
HTTPS_PROXY=http://proxy.example.com:3128
HTTP_PROXY=http://proxy.example.com:3128
https_proxy=http://proxy.example.com:3128
http_proxy=http://proxy.example.com:3128
no_proxy=10.10.0.0/21,10.194.48.0/21,localhost,127.0.0.1,169.254.169.254,169.254.170.2,.internal,.eu-central-1.eks.amazonaws.com,kubernetes.default,kubernetes.default.svc,kubernetes.default.svc.cluster,kubernetes.default.svc.cluster.local,.svc,.svc.cluster,.svc.cluster.local
NO_PROXY=10.10.0.0/21,10.194.48.0/21,localhost,127.0.0.1,169.254.169.254,169.254.170.2,.internal,.eu-central-1.eks.amazonaws.com,kubernetes.default,kubernetes.default.svc,kubernetes.default.svc.cluster,kubernetes.default.svc.cluster.local,.svc,.svc.cluster,.svc.cluster.local
I tried it with export no_proxy=$host
but it did not work.
Values from my example:
host=10.194.50.171
no_proxy=10.194.50.171
http_proxy=http://proxy.company-name.de:3128