diff --git a/bin/go-proxy b/bin/go-proxy index d9da5107..763fba8b 100755 Binary files a/bin/go-proxy and b/bin/go-proxy differ diff --git a/src/go-proxy/http_route.go b/src/go-proxy/http_route.go index ab092508..2d8afb49 100755 --- a/src/go-proxy/http_route.go +++ b/src/go-proxy/http_route.go @@ -49,11 +49,11 @@ func NewHTTPRoute(config *ProxyConfig) (*HTTPRoute, error) { PathMode: config.PathMode, } + director := proxy.Director proxy.Director = nil initRewrite := func(pr *httputil.ProxyRequest) { - pr.SetURL(url) - pr.SetXForwarded() + director(pr.Out) } rewrite := initRewrite @@ -78,7 +78,7 @@ func NewHTTPRoute(config *ProxyConfig) (*HTTPRoute, error) { } // disable cache r.Header.Set("Cache-Control", "no-store") - + var err error = nil switch { case strings.HasPrefix(contentType[0], "text/html"):