Allowing proxying for secure cookies.

This commit is contained in:
2022-04-09 18:28:59 -05:00
parent 450fcfeb5a
commit 8e1ead37e6
4 changed files with 5 additions and 3 deletions

View File

@@ -14,6 +14,7 @@ const sessionConf = {
};
if (process.env.NODE_ENV === "production") {
sessionConf.cookie.secure = true;
sessionConf.proxy = true;
sessionConf.store = MongoStore.create({ mongoUrl: mongoURI, dbName: mongooseDbName });
}
export const userSession = session(sessionConf);