Skip to content

Commit

Permalink
bind: fix --proxy flag usage
Browse files Browse the repository at this point in the history
We no longer add default port, moreover the port is required.
  • Loading branch information
Choraden authored and mmatczuk committed Apr 22, 2024
1 parent 4420eb6 commit 09d0778
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions bind/flag.go
Original file line number Diff line number Diff line change
Expand Up @@ -94,11 +94,10 @@ func HTTPProxyConfig(fs *pflag.FlagSet, cfg *forwarder.HTTPProxyConfig, lcfg *lo
LogConfig(fs, lcfg)

fs.VarP(anyflag.NewValueWithRedact[*url.URL](cfg.UpstreamProxy, &cfg.UpstreamProxy, forwarder.ParseProxyURL, RedactURL),
"proxy", "x", "[protocol://]host[:port]"+
"proxy", "x", "<[protocol://]host:port>"+
"Upstream proxy to use. "+
"The supported protocols are: http, https, socks5. "+
"No protocol specified will be treated as HTTP proxy. "+
"If the port number is not specified, it is assumed to be 1080. "+
"The basic authentication username and password can be specified in the host string e.g. user:pass@host:port. "+
"Alternatively, you can use the -c, --credentials flag to specify the credentials. "+
"If both are specified, the proxy flag takes precedence. ")
Expand Down

0 comments on commit 09d0778

Please sign in to comment.