All the examples for node-http-proxy show a {target: <URL>} option, but I don't want to proxy to a single target. How do I set it up for outbound requests (to any URL)?

有帮助吗?

解决方案

Since node-http-proxy seems to be a proxy for inbound connections to a server farm, and not for outbound connections to random websites, I found another tool instead:

http://newspaint.wordpress.com/2012/11/05/node-js-http-and-https-proxy/

This allows me to customize the requests and responses as needed.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top