You've already forked golang-saas-starter-kit
mirror of
https://github.com/raseels-repos/golang-saas-starter-kit.git
synced 2025-06-15 00:15:15 +02:00
disable http2
This commit is contained in:
@ -95,7 +95,6 @@ func main() {
|
||||
Host string `default:"" envconfig:"HOST"`
|
||||
ReadTimeout time.Duration `default:"5s" envconfig:"READ_TIMEOUT"`
|
||||
WriteTimeout time.Duration `default:"5s" envconfig:"WRITE_TIMEOUT"`
|
||||
DisableHTTP2 bool `default:"false" envconfig:"DISABLE_HTTP2"`
|
||||
}
|
||||
Service struct {
|
||||
Name string `default:"web-api" envconfig:"SERVICE_NAME"`
|
||||
@ -601,9 +600,6 @@ func main() {
|
||||
}
|
||||
api.TLSConfig = &tls.Config{GetCertificate: m.GetCertificate}
|
||||
api.TLSConfig.NextProtos = append(api.TLSConfig.NextProtos, acme.ALPNProto)
|
||||
if !cfg.HTTPS.DisableHTTP2 {
|
||||
api.TLSConfig.NextProtos = append(api.TLSConfig.NextProtos, "h2")
|
||||
}
|
||||
|
||||
httpServers = append(httpServers, api)
|
||||
|
||||
|
@ -90,7 +90,6 @@ func main() {
|
||||
Host string `default:"" envconfig:"HOST"`
|
||||
ReadTimeout time.Duration `default:"5s" envconfig:"READ_TIMEOUT"`
|
||||
WriteTimeout time.Duration `default:"5s" envconfig:"WRITE_TIMEOUT"`
|
||||
DisableHTTP2 bool `default:"false" envconfig:"DISABLE_HTTP2"`
|
||||
}
|
||||
Service struct {
|
||||
Name string `default:"web-app" envconfig:"SERVICE_NAME"`
|
||||
@ -1010,9 +1009,6 @@ func main() {
|
||||
}
|
||||
api.TLSConfig = &tls.Config{GetCertificate: m.GetCertificate}
|
||||
api.TLSConfig.NextProtos = append(api.TLSConfig.NextProtos, acme.ALPNProto)
|
||||
if !cfg.HTTPS.DisableHTTP2 {
|
||||
api.TLSConfig.NextProtos = append(api.TLSConfig.NextProtos, "h2")
|
||||
}
|
||||
|
||||
httpServers = append(httpServers, api)
|
||||
|
||||
|
Reference in New Issue
Block a user