diff --git a/agent/consul/autopilotevents/ready_servers_events.go b/agent/consul/autopilotevents/ready_servers_events.go index 6e7734feeb..862959a127 100644 --- a/agent/consul/autopilotevents/ready_servers_events.go +++ b/agent/consul/autopilotevents/ready_servers_events.go @@ -310,6 +310,14 @@ func (r *ReadyServersEventPublisher) getGRPCPort(srv *autopilot.ServerState) int if err != nil || ns == nil || ns.Meta == nil { return 0 } + + if str, ok := ns.Meta["grpc_tls_port"]; ok { + grpcPort, err := strconv.Atoi(str) + if err == nil { + return grpcPort + } + } + if str, ok := ns.Meta["grpc_port"]; ok { grpcPort, err := strconv.Atoi(str) if err == nil {