summaryrefslogtreecommitdiff
path: root/service/http/service.go
diff options
context:
space:
mode:
Diffstat (limited to 'service/http/service.go')
-rw-r--r--service/http/service.go9
1 files changed, 5 insertions, 4 deletions
diff --git a/service/http/service.go b/service/http/service.go
index 8e0d10ee..25b98a4c 100644
--- a/service/http/service.go
+++ b/service/http/service.go
@@ -209,10 +209,11 @@ func (s *Service) initSSL() *http.Server {
server := &http.Server{Addr: s.tlsAddr(s.cfg.Address, true), Handler: s}
s.throw(EventInitSSL, server)
- // Enable HTTP/2 support by default
- http2.ConfigureServer(server, &http2.Server{
- MaxConcurrentStreams: s.cfg.HTTP2.MaxConcurrentStreams,
- })
+ if s.cfg.HTTP2.Enabled {
+ http2.ConfigureServer(server, &http2.Server{
+ MaxConcurrentStreams: s.cfg.HTTP2.MaxConcurrentStreams,
+ })
+ }
return server
}