Restore original HTTP listener in monolith

This commit is contained in:
Neil Alexander 2020-04-20 15:10:38 +01:00
parent 8e67534959
commit 6c1c12b238

View file

@ -17,7 +17,6 @@ package main
import (
"flag"
"net/http"
"time"
"github.com/matrix-org/dendrite/appservice"
"github.com/matrix-org/dendrite/clientapi"
@ -92,14 +91,7 @@ func main() {
// Expose the matrix APIs directly rather than putting them under a /api path.
go func() {
logrus.Info("Listening on ", *httpBindAddr)
serv := http.Server{
Addr: *httpBindAddr,
ReadTimeout: time.Second * 300,
ReadHeaderTimeout: time.Second * 300,
WriteTimeout: time.Second * 300,
IdleTimeout: time.Second * 300,
}
logrus.Fatal(serv.ListenAndServe())
logrus.Fatal(http.ListenAndServe(*httpBindAddr, nil))
}()
// Handle HTTPS if certificate and key are provided
go func() {