diff --git a/apps/run.go b/apps/run.go index cb15c8468..7f8d8fde6 100644 --- a/apps/run.go +++ b/apps/run.go @@ -347,12 +347,6 @@ func (runCtx *runContext) connectToRunServer(ctx context.Context) (*http.Respons if err != nil { return nil, nil, errgo.Mask(err, errgo.Any) } - httpClient := &http.Client{ - Transport: &http.Transport{ - Proxy: http.ProxyFromEnvironment, - TLSClientConfig: config.TLSConfig, - }, - } var conn *httputil.ClientConn if url.Scheme == "https" { @@ -367,7 +361,7 @@ func (runCtx *runContext) connectToRunServer(ctx context.Context) (*http.Respons return nil, nil, errgo.Newf("Invalid scheme format %s", url.Scheme) } - res, err := httpClient.Do(req) + res, err := conn.Do(req) if err != nil { if err, ok := err.(*net.OpError); ok { if err.Err.Error() == "record overflow" {