node: log intro with config path
This commit is contained in:
parent
0f24dd5f49
commit
18310268a5
@ -40,6 +40,7 @@ function Node(config) {
|
|||||||
if(!(this instanceof Node)) {
|
if(!(this instanceof Node)) {
|
||||||
return new Node(config);
|
return new Node(config);
|
||||||
}
|
}
|
||||||
|
this.configPath = config.path;
|
||||||
this.errors = errors;
|
this.errors = errors;
|
||||||
this.log = log;
|
this.log = log;
|
||||||
this.network = null;
|
this.network = null;
|
||||||
@ -215,6 +216,12 @@ Node.prototype._startService = function(serviceInfo, callback) {
|
|||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Node.prototype._logTitle = function() {
|
||||||
|
console.log('\n\n\n\n\n\n\n\n\n\n\n\n');
|
||||||
|
log.info('Using config:', this.configPath);
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Will start all running services in the order based on the dependency chain.
|
* Will start all running services in the order based on the dependency chain.
|
||||||
* @param {Function} callback - Called when all services are started
|
* @param {Function} callback - Called when all services are started
|
||||||
@ -223,6 +230,8 @@ Node.prototype.start = function(callback) {
|
|||||||
var self = this;
|
var self = this;
|
||||||
var servicesOrder = this.getServiceOrder();
|
var servicesOrder = this.getServiceOrder();
|
||||||
|
|
||||||
|
self._logTitle();
|
||||||
|
|
||||||
async.eachSeries(
|
async.eachSeries(
|
||||||
servicesOrder,
|
servicesOrder,
|
||||||
function(service, next) {
|
function(service, next) {
|
||||||
|
|||||||
@ -21,7 +21,7 @@ function getDefaultBaseConfig(options) {
|
|||||||
servicesConfig: {
|
servicesConfig: {
|
||||||
bitcoind: {
|
bitcoind: {
|
||||||
datadir: options.datadir || path.resolve(process.env.HOME, '.bitcoin'),
|
datadir: options.datadir || path.resolve(process.env.HOME, '.bitcoin'),
|
||||||
exec: path.resolve(__dirname, '../../dist/bitcoind')
|
exec: path.resolve(__dirname, '../../bin/bitcoind')
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -37,7 +37,7 @@ function getDefaultConfig(options) {
|
|||||||
servicesConfig: {
|
servicesConfig: {
|
||||||
bitcoind: {
|
bitcoind: {
|
||||||
datadir: path.resolve(defaultPath, './data'),
|
datadir: path.resolve(defaultPath, './data'),
|
||||||
exec: path.resolve(__dirname, '../../dist/bitcoind')
|
exec: path.resolve(__dirname, '../../bin/bitcoind')
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
@ -200,6 +200,7 @@ function start(options) {
|
|||||||
servicesPath = options.path; // defaults to the same directory
|
servicesPath = options.path; // defaults to the same directory
|
||||||
}
|
}
|
||||||
|
|
||||||
|
fullConfig.path = path.resolve(options.path, './bitcore-node.json');
|
||||||
fullConfig.services = start.setupServices(require, servicesPath, options.config);
|
fullConfig.services = start.setupServices(require, servicesPath, options.config);
|
||||||
|
|
||||||
var node = new BitcoreNode(fullConfig);
|
var node = new BitcoreNode(fullConfig);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user