fix blockchain start
This commit is contained in:
parent
4e20e82edf
commit
d36af9f5e1
|
@ -105,17 +105,7 @@ Blockchain.prototype.run = function() {
|
|||
console.error(err);
|
||||
return;
|
||||
}
|
||||
console.error(cmd);
|
||||
args = _.compact(args);
|
||||
|
||||
/*cmd = cmd.replace(/"/g, '').split(' --');
|
||||
let args = _.compact(cmd.splice(1)).map(arg => {
|
||||
return '--' + arg;
|
||||
});
|
||||
console.error('CMD', cmd[0]);*/
|
||||
console.error('ARGS', args);
|
||||
|
||||
console.log('CWD', process.cwd());
|
||||
const child = child_process.spawn(cmd, args, {cwd: process.cwd()});
|
||||
|
||||
child.on('error', (err) => {
|
||||
|
|
|
@ -88,7 +88,7 @@ class GethCommands {
|
|||
console.log(__('make sure you know what you are doing'));
|
||||
console.log('==================================');
|
||||
}
|
||||
cmd.push("--rpccorsdomain=\"" + config.rpcCorsDomain + "\"");
|
||||
cmd.push("--rpccorsdomain=" + config.rpcCorsDomain);
|
||||
} else {
|
||||
console.log('==================================');
|
||||
console.log(__('warning: cors is not set'));
|
||||
|
@ -112,7 +112,7 @@ class GethCommands {
|
|||
console.log(__('make sure you know what you are doing'));
|
||||
console.log('==================================');
|
||||
}
|
||||
cmd.push("--wsorigins=\"" + config.wsOrigins + "\"");
|
||||
cmd.push("--wsorigins=" + config.wsOrigins);
|
||||
} else {
|
||||
console.log('==================================');
|
||||
console.log(__('warning: wsOrigins is not set'));
|
||||
|
@ -192,12 +192,12 @@ class GethCommands {
|
|||
callback("");
|
||||
},
|
||||
function rpcApi(callback) {
|
||||
args.push('--rpcapi="' + rpc_api.join(',') + '"');
|
||||
callback(null, '--rpcapi="' + rpc_api.join(',') + '"');
|
||||
args.push('--rpcapi=' + rpc_api.join(','));
|
||||
callback(null, '--rpcapi=' + rpc_api.join(','));
|
||||
},
|
||||
function wsApi(callback) {
|
||||
args.push('--wsapi="' + ws_api.join(',') + '"');
|
||||
callback(null, '--wsapi="' + ws_api.join(',') + '"');
|
||||
args.push('--wsapi=' + ws_api.join(','));
|
||||
callback(null, '--wsapi=' + ws_api.join(','));
|
||||
},
|
||||
function accountToUnlock(callback) {
|
||||
let accountAddress = "";
|
||||
|
|
Loading…
Reference in New Issue