forked from PATRIC3/p3_web
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfig.js
59 lines (48 loc) · 1.35 KB
/
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
const fs = require('fs');
var nconf = require('nconf');
var defaults = {
"http_port": 3000,
"authorizationURL": "http://user.patric.local:3002/login",
"application_id": "patric3",
"p3_clientId": "patric3",
"p3_clientSecret": "patric3",
"redis": {
"host": "127.0.0.1",
"port": 6379,
"prefix": "",
"db": 1,
"pass": ""
},
"appLabel": "dev",
"cookieKey": "JSESSIONID",
"cookieDomain": ".patric.local",
"newsFeedRSS": "https://docs.patricbrc.org/news.rss",
"sessionTTL": 2628000000,
workspaceServiceURL: "",
appServiceURL: "",
dataURL: "",
accountURL: "http://user.patric.local:3002/",
docsServiceURL: "http://docs.patric.local/",
enableDevAuth: false,
devAuthorizationToken: "",
devUser: false,
enableDevTools: false,
reportProblemEmailAddress: "[email protected]",
"email": {
"localSendmail": false,
"defaultFrom": "PATRIC <[email protected]>",
"defaultSender": "PATRIC <[email protected]>",
"host": "",
"port":587
},
proxy: {
"brcdownloads": "http://brcdownloads.patricbrc.org"
}
};
var config_filename = "p3-web.conf";
var config_file = __dirname + "/" + config_filename;
if (!fs.statSync(config_file))
{
config_file = "./" + config_filename;
}
module.exports = nconf.argv().env().file(config_file).defaults(defaults);