forked from olizilla/athinavahla.com
-
Notifications
You must be signed in to change notification settings - Fork 0
/
keystone.js
executable file
·51 lines (39 loc) · 1.1 KB
/
keystone.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
// Simulate config options from your production environment by
// customising the .env file in your project's root folder.
require('dotenv').load();
// Require keystone
var keystone = require('keystone'),
handlebars = require('express3-handlebars');
keystone.init({
'name': 'Athina Vahla',
'brand': 'Athina Vahla',
'less': 'public',
'static': 'public',
'favicon': 'public/favicon.ico',
'views': 'templates/views',
'view engine': 'hbs',
'custom engine': handlebars.create({
layoutsDir: 'templates/views/layouts',
partialsDir: 'templates/views/',
defaultLayout: 'main',
helpers: new require('./templates/views/helpers')(),
extname: '.hbs'
}).engine,
'auto update': true,
'session': true,
'auth': true,
'user model': 'User',
'cookie secret': 'ahK@<{#K]HgycM)SxE[_Xivv/DueJkw3hHCeW{9WM0#|u#/Z}E_z3QmMI7"sanbq'
});
keystone.import('models');
keystone.set('locals', {
_: require('underscore'),
env: keystone.get('env'),
utils: keystone.utils,
editable: keystone.content.editable
});
keystone.set('routes', require('./routes'));
keystone.set('nav', {
'users': 'users'
});
keystone.start();