changes cherry picked from dev to stable (#169)
* lamassu-update to update crontab * lamassu update and install script to point to #stable branch * lamassu update and install script to point to #stable branch * removing outdated & unused script * crontab update fix + npm rebuild path fix
This commit is contained in:
parent
59cb5da61c
commit
9b7972017d
6 changed files with 15 additions and 304 deletions
|
|
@ -60,7 +60,12 @@ function processCryptos (codes) {
|
|||
|
||||
const blockchainDir = coinUtils.blockchainDir()
|
||||
const backupDir = path.resolve(os.homedir(), 'backups')
|
||||
const rsyncCmd = `echo "@daily rsync -r --prune-empty-dirs --include='*/' --include='wallet.dat' --exclude='*' ${blockchainDir} ${backupDir} > /dev/null" | crontab -`
|
||||
const rsyncCmd = `( \
|
||||
(crontab -l 2>/dev/null || echo -n "") | grep -v "@daily rsync ".*"wallet.dat"; \
|
||||
echo "@daily rsync -r --prune-empty-dirs --include='*/' \
|
||||
--include='wallet.dat' \
|
||||
--exclude='*' ${blockchainDir} ${backupDir} > /dev/null" \
|
||||
) | crontab -`
|
||||
common.es(rsyncCmd)
|
||||
|
||||
logger.info('Installation complete.')
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue