Description
A somewhat standard env var used in proxying applications is the HTTP_PROXY
and NO_PROXY
variables.
Undici should support automatically setting a global dispatcher if HTTP_PROXY env var is used. Currently Undici supports using setGlobalDispatcher()
method to set a specific proxy endpoint.
However there is a sister environment variable to HTTP_PROXY that supports contextually non-proxying domains: NO_PROXY
NO_PROXY requires a list of domain names to be NOT proxied and should make a request normally.
If any of the above cannot be supported, then Undici (and ultimately Node's Fetch-Undici) should allow per-request proxy settings or function hook to allow anyone to develop the same effect as HTTP_PROXY and NO_PROXY env var in their application that uses Undici/Node Fetch.
Thoughts?