diff --git a/services/real-time/app.js b/services/real-time/app.js index 2a024abc57..2373abb613 100644 --- a/services/real-time/app.js +++ b/services/real-time/app.js @@ -49,6 +49,7 @@ DeploymentManager.initialise() const app = express() const server = require('http').createServer(app) +server.keepAliveTimeout = Settings.keepAliveTimeoutMs const io = require('socket.io').listen(server, { logger: socketIoLogger, }) diff --git a/services/real-time/config/settings.defaults.js b/services/real-time/config/settings.defaults.js index b60655a24a..4252a8765c 100644 --- a/services/real-time/config/settings.defaults.js +++ b/services/real-time/config/settings.defaults.js @@ -166,6 +166,7 @@ const settings = { behindProxy: process.env.BEHIND_PROXY === 'true', trustedProxyIps: process.env.TRUSTED_PROXY_IPS, + keepAliveTimeoutMs: parseInt(process.env.KEEPALIVE_TIMEOUT_MS ?? '5000', 10), } // console.log settings.redis