From 3b35989ba36884c69d5dc511bba59789e9528b8a Mon Sep 17 00:00:00 2001 From: martind2000 Date: Thu, 10 Mar 2016 20:15:35 +0000 Subject: [PATCH] updated .gitignore file --- ecosystem.json | 4 ++-- web-server.js | 5 ++++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/ecosystem.json b/ecosystem.json index 911121d..51b9d4b 100644 --- a/ecosystem.json +++ b/ecosystem.json @@ -10,9 +10,9 @@ "script": "web-server.js", "cwd": "/var/www/silvrtree", "watch": true, - "max_restarts": 10, + "ignore_watch" : ["node_modules"], "merge_logs" : true, - "autorestart" : false, + "autorestart" : true, "restart_delay" : 3500, "max_memory_restart" : "300M", env: { diff --git a/web-server.js b/web-server.js index e274b3e..434081d 100644 --- a/web-server.js +++ b/web-server.js @@ -7,6 +7,8 @@ var express = require('express'), path = require('path'), http = require('http') //train = require('lib/train') /* ,submit = require('./routes/mongo/submit') */ ; + +var logger = require('log4js').getLogger(); var app = express(); GLOBAL.lastcheck = 0; var btcCache = {}, fxCache = {} , trainCache = {}; @@ -102,5 +104,6 @@ app.use('/btc', btc.doBTC); * create the server */ http.createServer(app).listen(app.get('port'), function () { - console.log("Express server listening on port " + app.get('port')); + logger.info("Express server listening on port " + app.get('port')); + //console.log("Express server listening on port " + app.get('port')); });