diff --git a/apps/run.go b/apps/run.go index 66c9e3be..b172f826 100644 --- a/apps/run.go +++ b/apps/run.go @@ -334,7 +334,7 @@ func (runCtx *runContext) connectToRunServer(ctx context.Context) (*http.Respons // Wrap with TLS if using HTTPS if url.Scheme == "https" { tlsConfig := config.TLSConfig.Clone() - tlsConfig.ServerName = strings.Split(url.Host, ":")[0] + tlsConfig.ServerName = url.Hostname() conn = tls.Client(conn, tlsConfig) }