Skip to content

Commit

Permalink
Convert final callsite
Browse files Browse the repository at this point in the history
  • Loading branch information
strideynet committed Nov 4, 2024
1 parent 69d4f42 commit 1543867
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions lib/tbot/service_identity_output.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ import (
"github.com/gravitational/trace"

"github.com/gravitational/teleport/api/client/proto"
"github.com/gravitational/teleport/api/client/webclient"
"github.com/gravitational/teleport/api/types"
"github.com/gravitational/teleport/lib/auth/authclient"
"github.com/gravitational/teleport/lib/config/openssh"
Expand Down Expand Up @@ -239,7 +238,7 @@ type alpnTester interface {
func renderSSHConfig(
ctx context.Context,
log *slog.Logger,
proxyPing *webclient.PingResponse,
proxyPing *proxyPingResponse,
clusterNames []string,
dest bot.Destination,
certAuthGetter certAuthGetter,
Expand All @@ -255,7 +254,11 @@ func renderSSHConfig(

proxyAddr := proxyPing.Proxy.SSH.PublicAddr
if proxyPing.Proxy.TLSRoutingEnabled {

var err error
proxyAddr, err = proxyPing.tlsRoutingProxyPublicAddr()
if err != nil {
return trace.Wrap(err, "determining tls routing address")
}
}

proxyHost, proxyPort, err := utils.SplitHostPort(proxyAddr)
Expand Down Expand Up @@ -315,7 +318,7 @@ func renderSSHConfig(
connUpgradeRequired := false
if proxyPing.Proxy.TLSRoutingEnabled {
connUpgradeRequired, err = alpnTester.isUpgradeRequired(
ctx, proxyPing.Proxy.SSH.PublicAddr, botCfg.Insecure,
ctx, proxyAddr, botCfg.Insecure,
)
if err != nil {
return trace.Wrap(err, "determining if ALPN upgrade is required")
Expand Down

0 comments on commit 1543867

Please sign in to comment.