X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/8b43f32b2c11d45f951bf4ff1bffab03d391ff41..2c61bf045e35d8971412880031412c4f1a9660f6:/lib/controller/railsproxy/railsproxy.go diff --git a/lib/controller/railsproxy/railsproxy.go b/lib/controller/railsproxy/railsproxy.go index 54257cffc5..515dd5df0f 100644 --- a/lib/controller/railsproxy/railsproxy.go +++ b/lib/controller/railsproxy/railsproxy.go @@ -8,16 +8,14 @@ package railsproxy import ( "fmt" - "net/http" "net/url" "strings" - "git.curoverse.com/arvados.git/lib/controller/rpc" - "git.curoverse.com/arvados.git/sdk/go/arvados" + "git.arvados.org/arvados.git/lib/controller/rpc" + "git.arvados.org/arvados.git/sdk/go/arvados" ) -// For now, FindRailsAPI always uses the rails API running on this -// node. +// FindRailsAPI always uses the rails API running on this node, for now. func FindRailsAPI(cluster *arvados.Cluster) (*url.URL, bool, error) { var best *url.URL for target := range cluster.Services.RailsAPI.InternalURLs { @@ -38,10 +36,5 @@ func NewConn(cluster *arvados.Cluster) *rpc.Conn { if err != nil { panic(err) } - conn := rpc.NewConn(cluster.ClusterID, url, insecure, rpc.PassthroughTokenProvider) - // If Rails is running with force_ssl=true, this - // "X-Forwarded-Proto: https" header prevents it from - // redirecting our internal request to an invalid https URL. - conn.SendHeader = http.Header{"X-Forwarded-Proto": []string{"https"}} - return conn + return rpc.NewConn(cluster.ClusterID, url, insecure, rpc.PassthroughTokenProvider) }