2022-05-14 10:22:06 +00:00
|
|
|
import invariant from "tiny-invariant";
|
|
|
|
|
|
|
|
invariant(typeof process.env.APP_BASE_URL === "string", `Please define the "APP_BASE_URL" environment variable`);
|
|
|
|
invariant(
|
|
|
|
typeof process.env.INVITATION_TOKEN_SECRET === "string",
|
|
|
|
`Please define the "INVITATION_TOKEN_SECRET" environment variable`,
|
|
|
|
);
|
|
|
|
invariant(typeof process.env.SESSION_SECRET === "string", `Please define the "SESSION_SECRET" environment variable`);
|
|
|
|
invariant(typeof process.env.AWS_SES_REGION === "string", `Please define the "AWS_SES_REGION" environment variable`);
|
|
|
|
invariant(
|
|
|
|
typeof process.env.AWS_SES_ACCESS_KEY_ID === "string",
|
|
|
|
`Please define the "AWS_SES_ACCESS_KEY_ID" environment variable`,
|
|
|
|
);
|
|
|
|
invariant(
|
|
|
|
typeof process.env.AWS_SES_ACCESS_KEY_SECRET === "string",
|
|
|
|
`Please define the "AWS_SES_ACCESS_KEY_SECRET" environment variable`,
|
|
|
|
);
|
|
|
|
invariant(
|
|
|
|
typeof process.env.AWS_SES_FROM_EMAIL === "string",
|
|
|
|
`Please define the "AWS_SES_FROM_EMAIL" environment variable`,
|
|
|
|
);
|
|
|
|
invariant(typeof process.env.REDIS_URL === "string", `Please define the "REDIS_URL" environment variable`);
|
2022-05-22 00:00:12 +00:00
|
|
|
invariant(
|
|
|
|
typeof process.env.MASTER_ENCRYPTION_KEY === "string",
|
|
|
|
`Please define the "MASTER_ENCRYPTION_KEY" environment variable`,
|
|
|
|
);
|
2022-05-30 00:21:42 +00:00
|
|
|
invariant(
|
|
|
|
typeof process.env.WEB_PUSH_VAPID_PRIVATE_KEY === "string",
|
|
|
|
`Please define the "WEB_PUSH_VAPID_PRIVATE_KEY" environment variable`,
|
|
|
|
);
|
|
|
|
invariant(
|
|
|
|
typeof process.env.WEB_PUSH_VAPID_PUBLIC_KEY === "string",
|
|
|
|
`Please define the "WEB_PUSH_VAPID_PUBLIC_KEY" environment variable`,
|
|
|
|
);
|
2022-07-01 23:49:12 +00:00
|
|
|
invariant(typeof process.env.FATHOM_SITE_ID === "string", `Please define the "FATHOM_SITE_ID" environment variable`);
|
2022-05-14 10:22:06 +00:00
|
|
|
|
|
|
|
export default {
|
|
|
|
app: {
|
|
|
|
baseUrl: process.env.APP_BASE_URL,
|
|
|
|
invitationTokenSecret: process.env.INVITATION_TOKEN_SECRET,
|
|
|
|
sessionSecret: process.env.SESSION_SECRET,
|
2022-05-22 00:00:12 +00:00
|
|
|
encryptionKey: process.env.MASTER_ENCRYPTION_KEY,
|
2022-05-14 10:22:06 +00:00
|
|
|
},
|
|
|
|
awsSes: {
|
|
|
|
awsRegion: process.env.AWS_SES_REGION,
|
|
|
|
accessKeyId: process.env.AWS_SES_ACCESS_KEY_ID,
|
|
|
|
secretAccessKey: process.env.AWS_SES_ACCESS_KEY_SECRET,
|
|
|
|
fromEmail: process.env.AWS_SES_FROM_EMAIL,
|
|
|
|
},
|
2022-07-01 23:49:12 +00:00
|
|
|
fathom: {
|
|
|
|
siteId: process.env.FATHOM_SITE_ID,
|
|
|
|
domain: process.env.FATHOM_CUSTOM_DOMAIN,
|
2022-06-26 18:57:44 +00:00
|
|
|
},
|
2022-05-14 10:22:06 +00:00
|
|
|
redis: {
|
|
|
|
url: process.env.REDIS_URL,
|
|
|
|
password: process.env.REDIS_PASSWORD,
|
|
|
|
},
|
2022-06-26 15:01:55 +00:00
|
|
|
sentry: {
|
|
|
|
dsn: process.env.SENTRY_DSN,
|
|
|
|
},
|
2022-05-30 00:21:42 +00:00
|
|
|
webPush: {
|
|
|
|
privateKey: process.env.WEB_PUSH_VAPID_PRIVATE_KEY,
|
|
|
|
publicKey: process.env.WEB_PUSH_VAPID_PUBLIC_KEY,
|
|
|
|
},
|
2022-05-14 10:22:06 +00:00
|
|
|
};
|