|
|
|
|
|
|
|
|
// Instead of waiting for the root to be establised we start working at the current locatoin and then relocate when root changes. |
|
|
// Instead of waiting for the root to be establised we start working at the current locatoin and then relocate when root changes. |
|
|
var runlogjson = `${selectedinstance.root}/.elxr/run-${runtimestamp}/run.log` |
|
|
var runlogjson = `${selectedinstance.root}/.elxr/run-${runtimestamp}/run.log` |
|
|
ensureDirectoryExistence(runlogjson) |
|
|
ensureDirectoryExistence(runlogjson) |
|
|
fs.writeFileSync(runlogjson, JSON.stringify( `Started ${runtimestamp}`)) // Initialize a new log file with "logrotate" for every run |
|
|
|
|
|
|
|
|
fs.writeFileSync(runlogjson, JSON.stringify( { message : `Started ${runtimestamp}`, success:true})) // Initialize a new log file with "logrotate" for every run |
|
|
Tasq.addlistener((e)=>{ fs.writeFileSync(runlogjson, ', ' + JSON.stringify( e ), { 'flag': 'a+' }) }) |
|
|
Tasq.addlistener((e)=>{ fs.writeFileSync(runlogjson, ', ' + JSON.stringify( e ), { 'flag': 'a+' }) }) |
|
|
var cli = require('./cliverse') |
|
|
var cli = require('./cliverse') |
|
|
function isWin(){ return /^win/.test(process.platform) } |
|
|
function isWin(){ return /^win/.test(process.platform) } |
|
|
|
|
|
|
|
|
return __acquireConfig(selected, { remote : 'userfork' } // PB : TODO -- accessiblity state should switch to public etc.. |
|
|
return __acquireConfig(selected, { remote : 'userfork' } // PB : TODO -- accessiblity state should switch to public etc.. |
|
|
, selected.instanceName + '-config-' + selected.node_env + `-${clusternodename}` |
|
|
, selected.instanceName + '-config-' + selected.node_env + `-${clusternodename}` |
|
|
, function(e){ console.info('Customized node level config not found. This is not an Error. Will attempt with owner level config.'); |
|
|
, function(e){ console.info('Customized node level config not found. This is not an Error. Will attempt with owner level config.'); |
|
|
|
|
|
e.benign = true |
|
|
return e; } |
|
|
return e; } |
|
|
) |
|
|
) |
|
|
} |
|
|
} |
|
|
, ownerInstnace(selected) { return __acquireConfig(selected, { remote : 'userfork' } |
|
|
, ownerInstnace(selected) { return __acquireConfig(selected, { remote : 'userfork' } |
|
|
, selected.instanceName + '-config-' + selected.node_env |
|
|
, selected.instanceName + '-config-' + selected.node_env |
|
|
, function(e){ console.info('Customized user level config not found. This is not an Error. Will attempt global common instance config.'); |
|
|
, function(e){ console.info('Customized user level config not found. This is not an Error. Will attempt global common instance config.'); |
|
|
|
|
|
e.benign = true |
|
|
return e } |
|
|
return e } |
|
|
) |
|
|
) |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
return __acquireData(selected, { remote : 'userfork' } |
|
|
return __acquireData(selected, { remote : 'userfork' } |
|
|
, selected.instanceName + '-data-' + selected.node_env + `-${clusternodename}` |
|
|
, selected.instanceName + '-data-' + selected.node_env + `-${clusternodename}` |
|
|
, function(e){ console.info('Customized node level data not found. This is not an Error. Will attempt with owner level config.'); |
|
|
, function(e){ console.info('Customized node level data not found. This is not an Error. Will attempt with owner level config.'); |
|
|
|
|
|
e.benign = true |
|
|
return e; } |
|
|
return e; } |
|
|
) |
|
|
) |
|
|
} |
|
|
} |
|
|
, ownerInstnace(selected) { return __acquireData(selected, { remote : 'userfork' } |
|
|
, ownerInstnace(selected) { return __acquireData(selected, { remote : 'userfork' } |
|
|
, selected.instanceName + '-data-' + selected.node_env |
|
|
, selected.instanceName + '-data-' + selected.node_env |
|
|
, function(e){ console.info('Customized user level data not found. This is not an Error. Will attempt global common instance config.'); |
|
|
, function(e){ console.info('Customized user level data not found. This is not an Error. Will attempt global common instance config.'); |
|
|
|
|
|
e.benign = true |
|
|
return e } |
|
|
return e } |
|
|
) |
|
|
) |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
// https://git-scm.com/book/en/v2/Git-Tools-Credential-Storage |
|
|
// https://git-scm.com/book/en/v2/Git-Tools-Credential-Storage |
|
|
// Git Credential storage... |
|
|
// Git Credential storage... |
|
|
// git config --global credential.helper 'store --file ~/.gitcredentials' |
|
|
// git config --global credential.helper 'store --file ~/.gitcredentials' |
|
|
|
|
|
// git credential fill |
|
|
|
|
|
// protocol=https |
|
|
|
|
|
// host=git.bbh.org.in |
|
|
|
|
|
// username=bob |
|
|
|
|
|
// password=pppp |
|
|
// git credential-store --file ~/.gitcredentials store |
|
|
// git credential-store --file ~/.gitcredentials store |
|
|
|
|
|
|
|
|
// // notepad C:/Program Files/Git/etc/gitconfig |
|
|
// // notepad C:/Program Files/Git/etc/gitconfig |
|
|
// git config --edit --system |
|
|
// git config --edit --system |
|
|
// git config --global credential.helper "store --file ~/gitcredentials" |
|
|
|
|
|
// git credential fill |
|
|
|
|
|
|
|
|
|
|
|
// git credential-store --file ~/git.store store |
|
|
// git credential-store --file ~/git.store store |
|
|
|
|
|
|
|
|
// Find system git config |
|
|
// Find system git config |