diff --git a/loader.js b/loader.js index 20566625e2..4ce2d84604 100644 --- a/loader.js +++ b/loader.js @@ -1,7 +1,6 @@ 'use strict'; var nconf = require('nconf'), - net = require('net'), fs = require('fs'), url = require('url'), path = require('path'), @@ -16,7 +15,6 @@ var nconf = require('nconf'), output = logrotate({ file: __dirname + '/logs/output.log', size: '1m', keep: 3, compress: true }), silent = process.env.NODE_ENV !== 'development', numProcs, - workers = [], Loader = { @@ -153,6 +151,7 @@ Loader.addWorkerEvents = function(worker) { }; Loader.start = function(callback) { + numProcs = getPorts().length; console.log('Clustering enabled: Spinning up ' + numProcs + ' process(es).\n'); for (var x=0; x