var express = require('express'); var path = require('path'); var http = require('http'); var favicon = require('serve-favicon'); var logger = require('morgan'); var cookieParser = require('cookie-parser'); var bodyParser = require('body-parser'); var keeper = require('./server/keeper'); var app = express(); app.set('port', process.env.PORT || 8025); app.set('views', path.join(__dirname, 'views')); app.set('view engine', 'ejs'); app.use(logger('dev')); app.use(bodyParser.json()); app.use(bodyParser.urlencoded({ extended: true })); app.use(cookieParser()); app.use(express.static(path.join(__dirname, 'dist'))); app.use('/', keeper); /** * create the server */ app.listen(app.get('port'), function () { console.log('Keeper Server listening on ' + app.get('port')); });/** * Created by Martin on 22/02/2016. */