Browse Source

redirecting the internal logging of the vulcand/oxy to our /dev/null

Mohamed Al Ashaal 7 years ago
parent
commit
fa6a08cecb
1 changed files with 3 additions and 0 deletions
  1. 3 0
      server.go

+ 3 - 0
server.go

@@ -4,10 +4,12 @@ import (
 	"context"
 	"crypto/tls"
 	"errors"
+	"io/ioutil"
 	"net/http"
 )
 
 import (
+	log "github.com/sirupsen/logrus"
 	"github.com/vulcand/oxy/forward"
 	"github.com/vulcand/oxy/roundrobin"
 	"github.com/vulcand/oxy/testutils"
@@ -32,6 +34,7 @@ func InitServer() error {
 		TLSConfig: &tls.Config{GetCertificate: m.GetCertificate},
 		Handler:   ServeHTTP(),
 	}
+	log.SetOutput(ioutil.Discard)
 	return s.ListenAndServeTLS("", "")
 }