--use-env-proxy
启用后,Node.js 在启动时会解析 HTTP_PROXY、HTTPS_PROXY 和 NO_PROXY 环境变量,并通过指定的代理路由请求。
🌐 When enabled, Node.js parses the HTTP_PROXY, HTTPS_PROXY and NO_PROXY
environment variables during startup, and routes requests through the
specified proxy.
仅在受信任且被授权用于部署的代理上使用此功能。代理支持是为了通过授权的代理服务器访问外部网络,例如当防火墙要求使用代理时。它不是用来隐藏流量或规避网络策略的。见 内置代理支持。
🌐 Use this only with proxies that are trusted and authorized for the deployment. Proxy support is intended for reaching external networks through authorized proxy servers, for example when a firewall requires one. It is not for hiding traffic or evading network policy. See Built-in Proxy Support.
这相当于设置 NODE_USE_ENV_PROXY=1 环境变量。当两者都设置时,--use-env-proxy 优先。
🌐 This is equivalent to setting the NODE_USE_ENV_PROXY=1 environment variable.
When both are set, --use-env-proxy takes precedence.