forked from softwerkskammer/Agora
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfigure.js
53 lines (49 loc) · 1.53 KB
/
configure.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
'use strict';
process.chdir(__dirname);
var nconf = require('nconf');
var Beans = require('CoolBeans');
function createConfiguration() {
// create an nconf object, and initialize it with given values from
// the environment variables and/or from the command line
nconf.argv().env();
nconf.file('mongo', './config/mongo-config.json');
nconf.file('sympa', './config/sympa-config.json');
nconf.file('server', './config/server-config.json');
nconf.file('authentication', './config/authentication-config.json');
nconf.file('mail', './config/mailsender-config.json');
nconf.file('wiki', './config/wikirepo-config.json');
nconf.file('gallery', './config/gallery-config.json');
nconf.file('activityresults', './config/activityresults-config.json');
nconf.defaults({
adminListName: "admins",
port: '17124',
imageDirectory: "/tmp",
mongoHost: 'localhost',
mongoPort: '27017',
mongoDB: 'swk',
publicUrlPrefix: 'http://localhost:17124',
securedByLoginURLPattern:
'/activityresults|' +
'/gallery|' +
'/mailsender|' +
'/members|' +
'/new|' +
'/edit|' +
'/submit|' +
'(subscribe|unsubscribe)/|' +
'/mailarchive|' +
'/invitation|' +
'/addToWaitinglist|' +
'/removeFromWaitinglist|' +
'/addon|' +
'/submitAddon|' +
'/wiki/socrates.*/|' +
'/payment|' +
'dashboard',
secret: 'secret',
beans: new Beans('./config/beans.json'),
domainname: 'localhost'
});
return nconf;
}
module.exports = createConfiguration();