mirror of https://github.com/coder/coder.git
fix: Disable ErrorLog in http.Server (#1244)
Vault does similarly: e2490059d0/command/server.go (L2714)
These messages have primarily been noise.
This commit is contained in:
parent
b948f2dab5
commit
9b37a0de31
|
@ -8,6 +8,8 @@ import (
|
|||
"encoding/pem"
|
||||
"errors"
|
||||
"fmt"
|
||||
"io"
|
||||
"log"
|
||||
"net"
|
||||
"net/http"
|
||||
"net/url"
|
||||
|
@ -263,7 +265,10 @@ func server() *cobra.Command {
|
|||
go func() {
|
||||
defer close(errCh)
|
||||
server := http.Server{
|
||||
Handler: handler,
|
||||
// These errors are typically noise like "TLS: EOF". Vault does similar:
|
||||
// https://github.com/hashicorp/vault/blob/e2490059d0711635e529a4efcbaa1b26998d6e1c/command/server.go#L2714
|
||||
ErrorLog: log.New(io.Discard, "", 0),
|
||||
Handler: handler,
|
||||
BaseContext: func(_ net.Listener) context.Context {
|
||||
return shutdownConnsCtx
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue