diff --git a/lib/http-worker.js b/lib/http-worker.js index c3ed9754c..147a7d841 100644 --- a/lib/http-worker.js +++ b/lib/http-worker.js @@ -599,9 +599,9 @@ app.use(function (err, req, res /*, next*/) { var server = Http.createServer(app); nThen(function (w) { - server.listen(Env.httpPort, w()); + server.listen(Env.httpPort, Env.httpAddress, w()); if (Env.httpSafePort) { - server.listen(Env.httpSafePort, w()); + server.listen(Env.httpSafePort, Env.httpAddress, w()); } server.on('upgrade', function (req, socket, head) { // TODO warn admins that websockets should only be proxied in this way in a dev environment diff --git a/server.js b/server.js index 8c295fef9..b30e77e27 100644 --- a/server.js +++ b/server.js @@ -81,7 +81,7 @@ nThen(function (w) { process.exit(1); } Env.httpServer = Http.createServer(app); - Env.httpServer.listen(Env.websocketPort, 'localhost', w(function () { + Env.httpServer.listen(Env.websocketPort, Env.httpAddress, w(function () { Env.Log.info('WEBSOCKET_LISTENING', { port: Env.websocketPort, });