1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-07-23 15:29:42 +02:00

fix(environments): don't override with local IP [EE-1561] (#5785)

fix(environments): don't override with local IP [EE-1561] (#5785)
This commit is contained in:
Marcelo Rydel 2021-10-14 09:40:14 -03:00 committed by GitHub
parent 158cdf596a
commit 12e7aa6b60
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 4 deletions

View file

@ -52,9 +52,9 @@ func (factory *ProxyFactory) newKubernetesLocalProxy(endpoint *portainer.Endpoin
func (factory *ProxyFactory) newKubernetesEdgeHTTPProxy(endpoint *portainer.Endpoint) (http.Handler, error) {
tunnel := factory.reverseTunnelService.GetTunnelDetails(endpoint.ID)
endpoint.URL = fmt.Sprintf("http://localhost:%d", tunnel.Port)
rawURL := fmt.Sprintf("http://localhost:%d", tunnel.Port)
endpointURL, err := url.Parse(endpoint.URL)
endpointURL, err := url.Parse(rawURL)
if err != nil {
return nil, err
}