Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | 5x 5x | import "dotenv/config";
const env = process.env;
const app = {
port: env.PORT ?? 6010,
name: env.ENV_NAME ? `wlog:${env.ENV_NAME}` : "wlog",
http: {
session: {
secret: env.SESSION_SECRET,
unset: "destroy",
resave: false,
saveUninitialized: true,
cookie: {
httpOnly: true, // By design, our client won't rely on Javascript
sameSite: true,
secure: env.NODE_ENV == "production" // HTTPS only enabled for prod environment
}
}
},
};
export default app;
|