This article is about 200 words, it will take about 3 minutes to read it, please correct any mistakes.

The problem

1. Failed to access Google while requesting node.js.

2. When Node serves as an intermediate proxy server, software such as Fiddler, whistle, and Charles can’t catch requests from Node, making debugging difficult.

measures

1. Add proxy properties

Request.js is used as an example here. Any other request library will have a proxy property.

Disadvantages: Need to modify the source code

measures

2. Use the system agent tool, such as Proxifier

Put a link. www.cnblogs.com/wayneliu007…

Cons: Additional software needs to be installed, and configuration is required.

3. http_proxy

The export http_proxy=’your proxy address’ command line does not need to install software and modify the source code.

reference

  • www.cnblogs.com/wayneliu007…
  • Segmentfault.com/a/119000001…