Increase session expiry time

This commit is contained in:
Neeraj 2024-10-17 17:05:58 +05:30 committed by Nabarun
parent 734917f87b
commit 24e5e8e8b1

View File

@ -86,8 +86,7 @@ export const createAndStartServer = async (
saveUninitialized: true, saveUninitialized: true,
cookie: { cookie: {
secure: new URL(appOriginUrl).protocol === 'https:', secure: new URL(appOriginUrl).protocol === 'https:',
// 23 hours (less than 24 hours to avoid sessionSigs expiration issues) maxAge: 30 * 24 * 60 * 60 * 1000,
maxAge: 23 * 60 * 60 * 1000,
domain: domain || undefined, domain: domain || undefined,
sameSite: new URL(appOriginUrl).protocol === 'https:' ? 'none' : 'lax', sameSite: new URL(appOriginUrl).protocol === 'https:' ? 'none' : 'lax',
} }