Backend: Adds support for HTTP/2 (#18358)

* Backend: Adds support for HTTP/2

* Adds mozilla recommended ciphers

* Updates sample.ini and config documentation
This commit is contained in:
kay delaney
2019-08-16 16:06:54 +01:00
committed by GitHub
parent bf82e6cded
commit fb0cec5591
6 changed files with 57 additions and 6 deletions
+6
View File
@@ -29,6 +29,7 @@ type Scheme string
const (
HTTP Scheme = "http"
HTTPS Scheme = "https"
HTTP2 Scheme = "h2"
SOCKET Scheme = "socket"
DEFAULT_HTTP_ADDR string = "0.0.0.0"
)
@@ -639,6 +640,11 @@ func (cfg *Cfg) Load(args *CommandLineArgs) error {
CertFile = server.Key("cert_file").String()
KeyFile = server.Key("cert_key").String()
}
if protocolStr == "h2" {
Protocol = HTTP2
CertFile = server.Key("cert_file").String()
KeyFile = server.Key("cert_key").String()
}
if protocolStr == "socket" {
Protocol = SOCKET
SocketPath = server.Key("socket").String()