forked from okfn/opendatasurvey
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrun.js
More file actions
28 lines (23 loc) · 659 Bytes
/
Copy pathrun.js
File metadata and controls
28 lines (23 loc) · 659 Bytes
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
var model = require('./lib/model').OpenDataCensus
, census = require('./routes/census')
, config = require('./lib/config')
;
// Booting up
// ========================================================
if (config.get('debug')) {
console.log(config.get());
}
model.load(function(err) {
if (err) {
console.error('Failed to load dataset info');
throw err;
}
app = require('./app').app
// Passport Auth Stuff (Facebook etc)
// set up here rather than app.js as must be after config load to
// get site_url
census.setupAuth();
app.listen(app.get('port'), function() {
console.log("Listening on " + app.get('port'));
});
});