If you’re stuck on golang how to use forward http proxy, this might help:
```go
func newProxyClient(proxyAddr string) *http.Client {
proxy, _ := url.Parse(proxyAddr)
return &http.Client{
Transport: &http.Transport{Proxy: http.ProxyURL(proxy)},
}
}
```
Bonus: Use `curl -x` to test your proxy manually first. Saves a ton of debugging time.
```go
func newProxyClient(proxyAddr string) *http.Client {
proxy, _ := url.Parse(proxyAddr)
return &http.Client{
Transport: &http.Transport{Proxy: http.ProxyURL(proxy)},
}
}
```
Bonus: Use `curl -x` to test your proxy manually first. Saves a ton of debugging time.
