Fixed http2 issue

This commit is contained in:
Kasper Rynning-Tønnesen
2018-03-09 18:22:41 +01:00
parent 9b7be4224a
commit 79fa8805b2

View File

@@ -78,10 +78,10 @@ function startSingle(clustered, redis_enabled) {
ca: ca
};
var https = require('https');
server = require('http2').createSecureServer(credentials, routingFunction);
server = https.Server(credentials, routingFunction);
} catch(err){
console.log("Starting without https (probably on localhost)");
server = require('http2').createServer(routingFunction);
server = http.createServer(routingFunction);
}
if(clustered) {