Merge pull request #9083 from overleaf/ho-redis-sessions-config

split websessions web config into separate config section & point sessions to existing redis

GitOrigin-RevId: 2f5798d7c7502ad8dced90f88c559a5572843771
This commit is contained in:
Henry Oswald 2022-08-08 08:55:04 +01:00 committed by Copybot
parent cb1af54428
commit aa999d6f2f

View file

@ -65,12 +65,15 @@ const settings = {
},
websessions: {
host: process.env.WEB_REDIS_HOST || process.env.REDIS_HOST || 'localhost',
port: process.env.WEB_REDIS_PORT || process.env.REDIS_PORT || '6379',
host:
process.env.SESSIONS_REDIS_HOST ||
process.env.REDIS_HOST ||
'localhost',
port: process.env.SESSIONS_REDIS_PORT || process.env.REDIS_PORT || '6379',
password:
process.env.WEB_REDIS_PASSWORD || process.env.REDIS_PASSWORD || '',
process.env.SESSIONS_REDIS_PASSWORD || process.env.REDIS_PASSWORD || '',
maxRetriesPerRequest: parseInt(
process.env.WEB_REDIS_MAX_RETRIES_PER_REQUEST ||
process.env.SESSIONS_REDIS_MAX_RETRIES_PER_REQUEST ||
process.env.REDIS_MAX_RETRIES_PER_REQUEST ||
'20'
),