From e0faf7975f930531016e7b49b1030c467b91460b Mon Sep 17 00:00:00 2001 From: Matthew Saunders Brown Date: Thu, 21 Jan 2021 16:56:59 -0800 Subject: [PATCH] added quickstart --- README.md | 24 ++++++++++++++++++++++-- bashup-backup-files.sh | 0 bashup-backup-mysql.sh | 0 bashup-backup-pdns.sh | 0 bashup-list-backups.sh | 0 bashup-restore-files.sh | 0 bashup-restore-mysql.sh | 0 7 files changed, 22 insertions(+), 2 deletions(-) mode change 100644 => 100755 bashup-backup-files.sh mode change 100644 => 100755 bashup-backup-mysql.sh mode change 100644 => 100755 bashup-backup-pdns.sh mode change 100644 => 100755 bashup-list-backups.sh mode change 100644 => 100755 bashup-restore-files.sh mode change 100644 => 100755 bashup-restore-mysql.sh diff --git a/README.md b/README.md index bbad452..743c44f 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,23 @@ -# BashUP +# Bashup -A set of bash scripts for managing backups. \ No newline at end of file +A set of bash scripts for managing backups. + +## Quickstart + +Create a backup directory or mount. For example, make a directory named /mnt/backups and create an NFS mount for that directory. + +```bash +cd /usr/local/src/ +wget https://git.stack-source.com/msb/bashup/archive/master.tar.gz -O bashup.tar.gz +tar zxvf bashup.tar.gz +cd bashup +cp bashup-*.sh /usr/local/sbin/ +chmod 750 /usr/local/sbin/bashup-*.sh +chown root:root /usr/local/sbin/bashup-*.sh +nano /usr/local/etc/bashup.cnf +crontab -e +``` + +The "nano /usr/local/etc/bashup.cnf" command is optional. Do this if you need to override any of the settings at the top of the bashup scripts. +For the crontab add an entry for each of the "bashup-backup-*.sh" scripts that you'd like to run. For example, to back up files at 3:01 am every day add this crontab: +`1 3 * * * /usr/local/sbin/bashup-backup-files.sh` diff --git a/bashup-backup-files.sh b/bashup-backup-files.sh old mode 100644 new mode 100755 diff --git a/bashup-backup-mysql.sh b/bashup-backup-mysql.sh old mode 100644 new mode 100755 diff --git a/bashup-backup-pdns.sh b/bashup-backup-pdns.sh old mode 100644 new mode 100755 diff --git a/bashup-list-backups.sh b/bashup-list-backups.sh old mode 100644 new mode 100755 diff --git a/bashup-restore-files.sh b/bashup-restore-files.sh old mode 100644 new mode 100755 diff --git a/bashup-restore-mysql.sh b/bashup-restore-mysql.sh old mode 100644 new mode 100755