Use node-XMLHttpRequest through a Proxy?
问题 I need to deploy my node-XMLHttpRequest app to a server that uses a proxy to access the internet. In a terminal on that server, I can curl -d "" http://website/path and it works fine. I think curl recognizes the environment variable http_proxy in that case. The node app times out because it doesn't see the proxy. How can I get the node app to use the proxy? For instance, could I use http.globalAgent to send the requests through the proxy? 回答1: Did you provide the proxy options to the http