-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
746dc64
commit f9dd7cc
Showing
12 changed files
with
97 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
module.exports = { | ||
PORT: 5000, | ||
DB_URL: 'mongodb://localhost:27017/test-delta', | ||
EMAIL_VERIFICATION_TOKEN_EXPIRY: 15 * 60, // 15 minutes | ||
LOGIN_TOKEN_EXPIRY: '28d', | ||
LOGIN_COOKIE_EXPIRY: 4 * 7 * 24 * 60 * 60 * 1000, // 4 weeks | ||
...process.env, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
module.exports = { | ||
PORT: 5000, | ||
DB_URL: 'mongodb://localhost:27017/test-delta', | ||
EMAIL_VERIFICATION_TOKEN_EXPIRY: 15 * 60, // 15 minutes | ||
LOGIN_TOKEN_EXPIRY: '28d', | ||
LOGIN_COOKIE_EXPIRY: 4 * 7 * 24 * 60 * 60 * 1000, // 4 weeks | ||
...process.env, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
// The env var 'MODE' should be in ['PROD', 'DEV', 'CI'] | ||
const mode = process.env.MODE || 'DEV'; | ||
|
||
require('dotenv').load(); | ||
// eslint-disable-next-line import/no-dynamic-require | ||
module.exports = require(`./${mode.toLowerCase()}`); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
module.exports = { | ||
PORT: 5000, | ||
DB_URL: 'mongodb://localhost:27017/test-delta', | ||
EMAIL_VERIFICATION_TOKEN_EXPIRY: 15 * 60, // 15 minutes | ||
LOGIN_TOKEN_EXPIRY: '28d', | ||
LOGIN_COOKIE_EXPIRY: 4 * 7 * 24 * 60 * 60 * 1000, // 4 weeks | ||
...process.env, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
module.exports = { | ||
invalidToken: 'TOKEN_INVALID', | ||
missingToken: 'TOKEN_MISSING', | ||
expiredToken: 'TOKEN_EXPIRED', | ||
missingEmail: 'EMAIL_MISSING', | ||
invalidEmail: 'EMAIL_INVALID', | ||
internalServerError: 'Server error', | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
module.exports = { | ||
emailToken: 'EMAIL_VERIFICATION', | ||
loginToken: 'LOGIN', | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -857,6 +857,43 @@ | |
dependencies: | ||
any-observable "^0.3.0" | ||
|
||
"@sendgrid/client@^6.3.0": | ||
version "6.3.0" | ||
resolved "https://registry.yarnpkg.com/@sendgrid/client/-/client-6.3.0.tgz#25c34b11bec392ab43ca7e52fb35e4105fb00901" | ||
integrity sha512-fTy8vRpA9Whtf8ULQr/0vkSZaQvGQ97rY5N5PrevKRtugJMsJqFMKO0pwzEWeqITSg71aMMTj57QTgw3SjZvnQ== | ||
dependencies: | ||
"@sendgrid/helpers" "^6.3.0" | ||
"@types/request" "^2.0.3" | ||
request "^2.81.0" | ||
|
||
"@sendgrid/helpers@^6.3.0": | ||
version "6.3.0" | ||
resolved "https://registry.yarnpkg.com/@sendgrid/helpers/-/helpers-6.3.0.tgz#1b1798af22aa7a4c98257fab3dd2a6a6afd8b467" | ||
integrity sha512-uTFcmhCDFg/2Uhz+z/cLwyLHH0UsblG49hKwdR7nKbWsGKWv4js7W32FlPdXqy2C/plTJ20vcPLgKM1m3F/MjQ== | ||
dependencies: | ||
chalk "^2.0.1" | ||
deepmerge "^2.1.1" | ||
|
||
"@sendgrid/mail@^6.3.1": | ||
version "6.3.1" | ||
resolved "https://registry.yarnpkg.com/@sendgrid/mail/-/mail-6.3.1.tgz#e5003af167ca4dd358f04075aad4cfc30cef6c34" | ||
integrity sha512-5zIeAV9iU+0hQkrOQ/D4RB2MfpK+lNbOortIfQdCh95aMDF/TRc9WB8FGNhmQrx9YMuJTms5eiBklF0Fi/dbVg== | ||
dependencies: | ||
"@sendgrid/client" "^6.3.0" | ||
"@sendgrid/helpers" "^6.3.0" | ||
|
||
"@types/caseless@*": | ||
version "0.12.1" | ||
resolved "https://registry.yarnpkg.com/@types/caseless/-/caseless-0.12.1.tgz#9794c69c8385d0192acc471a540d1f8e0d16218a" | ||
integrity sha512-FhlMa34NHp9K5MY1Uz8yb+ZvuX0pnvn3jScRSNAb75KHGB8d3rEU6hqMs3Z2vjuytcMfRg6c5CHMc3wtYyD2/A== | ||
|
||
"@types/form-data@*": | ||
version "2.2.1" | ||
resolved "https://registry.yarnpkg.com/@types/form-data/-/form-data-2.2.1.tgz#ee2b3b8eaa11c0938289953606b745b738c54b1e" | ||
integrity sha512-JAMFhOaHIciYVh8fb5/83nmuO/AHwmto+Hq7a9y8FzLDcC1KCU344XDOMEmahnrTFlHjgh4L0WJFczNIX2GxnQ== | ||
dependencies: | ||
"@types/node" "*" | ||
|
||
"@types/jss@^9.5.6": | ||
version "9.5.6" | ||
resolved "https://registry.yarnpkg.com/@types/jss/-/jss-9.5.6.tgz#96e1d246ddfbccc4867494077c714773cf29acde" | ||
|
@@ -890,6 +927,21 @@ | |
"@types/prop-types" "*" | ||
csstype "^2.2.0" | ||
|
||
"@types/request@^2.0.3": | ||
version "2.47.1" | ||
resolved "https://registry.yarnpkg.com/@types/request/-/request-2.47.1.tgz#25410d3afbdac04c91a94ad9efc9824100735824" | ||
integrity sha512-TV3XLvDjQbIeVxJ1Z3oCTDk/KuYwwcNKVwz2YaT0F5u86Prgc4syDAp6P96rkTQQ4bIdh+VswQIC9zS6NjY7/g== | ||
dependencies: | ||
"@types/caseless" "*" | ||
"@types/form-data" "*" | ||
"@types/node" "*" | ||
"@types/tough-cookie" "*" | ||
|
||
"@types/tough-cookie@*": | ||
version "2.3.3" | ||
resolved "https://registry.yarnpkg.com/@types/tough-cookie/-/tough-cookie-2.3.3.tgz#7f226d67d654ec9070e755f46daebf014628e9d9" | ||
integrity sha512-MDQLxNFRLasqS4UlkWMSACMKeSm1x4Q3TxzUC7KQUsh6RK1ZrQ0VEyE3yzXcBu+K8ejVj4wuX32eUG02yNp+YQ== | ||
|
||
"@webassemblyjs/[email protected]": | ||
version "1.7.8" | ||
resolved "https://registry.yarnpkg.com/@webassemblyjs/ast/-/ast-1.7.8.tgz#f31f480debeef957f01b623f27eabc695fa4fe8f" | ||
|
@@ -2732,7 +2784,7 @@ deep-is@~0.1.3: | |
resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.3.tgz#b369d6fb5dbc13eecf524f91b070feedc357cf34" | ||
integrity sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ= | ||
|
||
deepmerge@^2.0.1: | ||
deepmerge@^2.0.1, deepmerge@^2.1.1: | ||
version "2.2.1" | ||
resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-2.2.1.tgz#5d3ff22a01c00f645405a2fbc17d0778a1801170" | ||
integrity sha512-R9hc1Xa/NOBi9WRVUWg19rl1UB7Tt4kuPd+thNJgFZoxXsTz7ncaPaeIm+40oSGuP33DfMb4sZt1QIGiJzC4EA== | ||
|