Skip to content

Commit

Permalink
backport of commit 49f7423
Browse files Browse the repository at this point in the history
  • Loading branch information
huikang committed Feb 17, 2023
1 parent 78c8e71 commit 289ed16
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion agent/agent.go
Original file line number Diff line number Diff line change
Expand Up @@ -933,7 +933,8 @@ func (a *Agent) listenHTTP() ([]apiServer, error) {
for _, l := range listeners {
var tlscfg *tls.Config
_, isTCP := l.(*tcpKeepAliveListener)
if isTCP && proto == "https" {
isUnix := l.Addr().Network() == "unix"
if (isTCP || isUnix) && proto == "https" {
tlscfg = a.tlsConfigurator.IncomingHTTPSConfig()
l = tls.NewListener(l, tlscfg)
}
Expand Down

0 comments on commit 289ed16

Please sign in to comment.