|
@ -289,7 +289,8 @@ shepherd.quitKomodod = function() { |
|
|
console.log(`stdout: ${stdout}`); |
|
|
console.log(`stdout: ${stdout}`); |
|
|
console.log(`stderr: ${stderr}`); |
|
|
console.log(`stderr: ${stderr}`); |
|
|
|
|
|
|
|
|
if (stdout.indexOf('stopping') > -1) { |
|
|
if (stdout.indexOf('stopping') > -1 || |
|
|
|
|
|
stdout.indexOf('EOF reached') > -1) { |
|
|
clearInterval(coindExitInterval[key]); |
|
|
clearInterval(coindExitInterval[key]); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
@ -1368,6 +1369,7 @@ function herder(flock, data) { |
|
|
}); |
|
|
}); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// TODO: notify gui that reindex/rescan param is used to reflect on the screen
|
|
|
if (flock === 'komodod') { |
|
|
if (flock === 'komodod') { |
|
|
let kmdDebugLogLocation = (data.ac_name !== 'komodod' ? komodoDir + '/' + data.ac_name : komodoDir) + '/debug.log'; |
|
|
let kmdDebugLogLocation = (data.ac_name !== 'komodod' ? komodoDir + '/' + data.ac_name : komodoDir) + '/debug.log'; |
|
|
|
|
|
|
|
@ -1424,7 +1426,7 @@ function herder(flock, data) { |
|
|
|
|
|
|
|
|
const isChain = data.ac_name.match(/^[A-Z]*$/); |
|
|
const isChain = data.ac_name.match(/^[A-Z]*$/); |
|
|
const coindACParam = isChain ? ` -ac_name=${data.ac_name} ` : ''; |
|
|
const coindACParam = isChain ? ` -ac_name=${data.ac_name} ` : ''; |
|
|
console.log('coindAC ' + coindACParam); |
|
|
console.log('daemon param ' + data.ac_custom_param); |
|
|
|
|
|
|
|
|
coindInstanceRegistry[data.ac_name] = true; |
|
|
coindInstanceRegistry[data.ac_name] = true; |
|
|
exec(`${komododBin} ${coindACParam}${data.ac_options.join(' ')}${_customParam}`, { |
|
|
exec(`${komododBin} ${coindACParam}${data.ac_options.join(' ')}${_customParam}`, { |
|
@ -1434,7 +1436,7 @@ function herder(flock, data) { |
|
|
shepherd.writeLog(`stderr: ${stderr}`); |
|
|
shepherd.writeLog(`stderr: ${stderr}`); |
|
|
|
|
|
|
|
|
if (error !== null) { |
|
|
if (error !== null) { |
|
|
console.log(`exec error: ${error}`) |
|
|
console.log(`exec error: ${error}`); |
|
|
shepherd.writeLog(`exec error: ${error}`); |
|
|
shepherd.writeLog(`exec error: ${error}`); |
|
|
|
|
|
|
|
|
if (error.toString().indexOf('using -reindex') > -1) { |
|
|
if (error.toString().indexOf('using -reindex') > -1) { |
|
@ -1615,7 +1617,7 @@ function setConf(flock) { |
|
|
|
|
|
|
|
|
const RemoveLines = function() { |
|
|
const RemoveLines = function() { |
|
|
return new Promise(function(resolve, reject) { |
|
|
return new Promise(function(resolve, reject) { |
|
|
const result = 'RemoveLines is done' |
|
|
const result = 'RemoveLines is done'; |
|
|
|
|
|
|
|
|
fs.readFile(DaemonConfPath, 'utf8', function(err, data) { |
|
|
fs.readFile(DaemonConfPath, 'utf8', function(err, data) { |
|
|
if (err) { |
|
|
if (err) { |
|
|