summaryrefslogtreecommitdiff
path: root/config.js
blob: 3a5c764c7720536e9262bfc4cb6cd697d745d1ac (plain)
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
//config
var path = require('path');

var config = {
    debug: true,
    version: '0.2.7',
    domain: 'http://localhost:3000',
    testport: '3000',
    //path
    tmppath: "./tmp/",
    defaultnotepath: path.join(__dirname, '/public', "default.md"),
    defaultfeaturespath: path.join(__dirname, '/public', "features.md"),
    hackmdpath: path.join(__dirname, '/public/views', "index.ejs"),
    errorpath: path.join(__dirname, '/public/views', "error.ejs"),
    prettypath: path.join(__dirname, '/public/views', 'pretty.ejs'),
    //db string
    postgresqlstring: "postgresql://localhost:5432/hackmd",
    mongodbstring: "mongodb://localhost/hackmd",
    //constants
    featuresnotename: "features",
    sessionname: 'please set this',
    sessionsecret: 'please set this',
    sessionlife: 14 * 24 * 60 * 60 * 1000, //14 days
    sessiontouch: 1 * 3600, //1 hour
    heartbeatinterval: 5000,
    heartbeattimeout: 10000,
    //auth
    facebook: {
        clientID: 'get yourself one',
        clientSecret: 'get yourself one',
        callbackPath: '/auth/facebook/callback'
    },
    twitter: {
        consumerKey: 'get yourself one',
        consumerSecret: 'get yourself one',
        callbackPath: '/auth/twitter/callback'
    },
    github: {
        clientID: 'get yourself one',
        clientSecret: 'get yourself one',
        callbackPath: '/auth/github/callback'
    },
    dropbox: {
        clientID: 'get yourself one',
        clientSecret: 'get yourself one',
        callbackPath: '/auth/dropbox/callback'
    }
};

module.exports = config;