Skip to main content

proxy_environment

Function proxy_environment 

Source
pub fn proxy_environment(port: u16, loopback: bool) -> Vec<(OsString, OsString)>
Expand description

The environment a program behind the namespace’s proxy gets, whatever [env] pass says (docs/NETWORK-ALLOWLIST.md §10.3: Go and Python read the upper- or lowercase variables; Node’s fetch needs NODE_USE_ENV_PROXY).

NO_PROXY keeps the namespace’s own loopback direct, except with loopback (the user added localhost or a loopback address): then those must reach the proxy, which allows this machine’s loopback with --allow-loopback and otherwise refuses with a hint, so NO_PROXY is empty.