-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathconfig.js
33 lines (28 loc) · 876 Bytes
/
config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
var extend = require("node.extend");
var _initialized = false;
var _config;
module.exports = function(key) {
var config = {
"databaseUser": "leaf-app",
//"databaseLocation": "ds048487.mongolab.com:48487/leaf-experimental",
"databaseLocation": "54.200.254.103:27017/leaf",
"hashAlgorithm": "sha512",
"dateFormat": "YYYY-MM-DD",
"dateTimeFormat": "YYYY-MM-DD HH:mm:ss",
"storageName" : "leafissuetracker",
"sendgridUsername": "LeafIssueTracker",
"fromAddress": "[email protected]",
"domain": "http://www.leafissuetracker.com",
"serverPort": 8080,
"buildNumber": require("./package.json").version
};
if (!_initialized) {
try {
extend(config, require("./secureConfig.json"));
} catch (e) {}
for (var name in config)
process.env["leaf." + name] = config[name];
_initialized = true;
}
return process.env["leaf." + key];
};