Permalink
Browse files

Only backup every 6 hours

  • Loading branch information...
NEMS Linux
NEMS Linux committed Jan 7, 2019
1 parent 1d8d5bb commit aef7022e8b494cced43faeff7a4730342d11067e
Showing with 8 additions and 0 deletions.
  1. +8 −0 backup.sh
@@ -12,6 +12,14 @@ ver=$(/usr/local/bin/nems-info nemsver)
nagvis="etc/maps/"
fi

# Only create a backup file every 6 hours.
if [[ -f /var/www/html/backup/snapshot/backup.nems ]]; then
if ! test `find "/var/www/html/backup/snapshot/backup.nems" -mmin +360`
then
# Current backup file is less than 6 hours old. Abort.
exit
fi
fi

mainpriv=''
mainpub=''

0 comments on commit aef7022

Please sign in to comment.