mirror of https://github.com/hashicorp/consul
agent: set proto to http since we are logging it now
parent
ceda18366f
commit
30ba712857
|
@ -448,6 +448,7 @@ func (a *Agent) serveHTTP(l net.Listener, srv *HTTPServer) error {
|
||||||
// we cannot just perform a type check since the compiler won't let
|
// we cannot just perform a type check since the compiler won't let
|
||||||
// us. We might be able to use reflection but the fmt.Sprintf() hack
|
// us. We might be able to use reflection but the fmt.Sprintf() hack
|
||||||
// works just as well.
|
// works just as well.
|
||||||
|
srv.proto = "http"
|
||||||
if strings.Contains("*tls.listener", fmt.Sprintf("%T", l)) {
|
if strings.Contains("*tls.listener", fmt.Sprintf("%T", l)) {
|
||||||
srv.proto = "https"
|
srv.proto = "https"
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue