fixed dotenv

This commit is contained in:
David Baldwynn 2016-05-20 14:11:37 -07:00
parent e5879e92c4
commit 2a1a6d5299
3 changed files with 11 additions and 5 deletions

View File

@ -1,9 +1,9 @@
{
"apps" : [{
"name" : "tellform",
"script" : "/usr/local/bin/grunt",
"instances" : "4",
"exec_mode" : "cluster"
"name" : "tellform",
"script" : "./node_modules/.bin/grunt",
"instances": "4",
"exec_mode": "cluster"
}],
"deploy" : {
"stage" : {

View File

@ -32,6 +32,7 @@
"connect-mongo": "~0.8.2",
"consolidate": "~0.13.1",
"cookie-parser": "~1.4.0",
"dotenv": "^2.0.0",
"email-verification": "whitef0x0/node-email-verification",
"envfile": "^2.0.1",
"express": "~4.13.3",

View File

@ -2,11 +2,16 @@
/**
* Module dependencies.
*/
//Load ENV vars from .env
require('dotenv').config();
var init = require('./config/init')(),
config = require('./config/config'),
mongoose = require('mongoose'),
chalk = require('chalk');
/**
* Main application entry file.
* Please note that the order of loading is important.
@ -50,5 +55,5 @@ console.log('--');
process.on('uncaughtException', function (err) {
console.error((new Date).toUTCString() + ' uncaughtException:', err.message);
console.error(err.stack);
process.exit(1)
process.exit(1);
});