From 82eff9d8ae0ca559278c04b8b5f09ede8e37b63a Mon Sep 17 00:00:00 2001 From: Asif Bacchus Date: Sun, 19 May 2019 21:35:12 -0600 Subject: [PATCH] new directory structure and template files --- SeafBackup/503.html | 29 +++++++++++++++++++++++++++ backup.sh => SeafBackup/backup.sh | 0 SeafBackup/excludeLocations.borg | 3 +++ SeafBackup/nc_borg.details | 8 ++++++++ SeafBackup/nc_sql.details | 4 ++++ SeafBackup/xtraLocations.borg | 33 +++++++++++++++++++++++++++++++ 6 files changed, 77 insertions(+) create mode 100644 SeafBackup/503.html rename backup.sh => SeafBackup/backup.sh (100%) create mode 100644 SeafBackup/excludeLocations.borg create mode 100644 SeafBackup/nc_borg.details create mode 100644 SeafBackup/nc_sql.details create mode 100644 SeafBackup/xtraLocations.borg diff --git a/SeafBackup/503.html b/SeafBackup/503.html new file mode 100644 index 0000000..ca562e7 --- /dev/null +++ b/SeafBackup/503.html @@ -0,0 +1,29 @@ + + + + + + 503 - Unavailable: Backup in progress + + + + + + +

Bad timing!

+

Seems you're trying to access me during my daily backup window. Don't + worry though, I should be up and running again very soon.

+

My average backup window duration is around 10 minutes during which time + I'm quite busy copying your super-important files to my ultra-secret hiding + place so they stay safe in case anything ever happens to me!

+

I'm really sorry for the delay. Please try me again soon!

+ + + \ No newline at end of file diff --git a/backup.sh b/SeafBackup/backup.sh similarity index 100% rename from backup.sh rename to SeafBackup/backup.sh diff --git a/SeafBackup/excludeLocations.borg b/SeafBackup/excludeLocations.borg new file mode 100644 index 0000000..62dd1ad --- /dev/null +++ b/SeafBackup/excludeLocations.borg @@ -0,0 +1,3 @@ +'/var/nc_data/cache' +sh:/var/nc_data/appdata_*/preview/ +EOF diff --git a/SeafBackup/nc_borg.details b/SeafBackup/nc_borg.details new file mode 100644 index 0000000..8e17e26 --- /dev/null +++ b/SeafBackup/nc_borg.details @@ -0,0 +1,8 @@ + /var/borgbackup + /var/borgbackup/sshPrivate.key + user@servername.tld:repoName/ + pAsSwOrd + /root/NCscripts/xtraLocations.borg + /root/NCscripts/excludeLocations.borg + --keep-within=7d --keep-daily=30 --keep-weekly=12 --keep-monthly=-1 + borg1 \ No newline at end of file diff --git a/SeafBackup/nc_sql.details b/SeafBackup/nc_sql.details new file mode 100644 index 0000000..810b73f --- /dev/null +++ b/SeafBackup/nc_sql.details @@ -0,0 +1,4 @@ + localhost + nextcloud + pAsSwOrd + nextcloudDB diff --git a/SeafBackup/xtraLocations.borg b/SeafBackup/xtraLocations.borg new file mode 100644 index 0000000..a3e6ab8 --- /dev/null +++ b/SeafBackup/xtraLocations.borg @@ -0,0 +1,33 @@ +/etc/fstab +/etc/network/interfaces +/etc/network/interfaces.d/ +/etc/systemd/timesyncd.conf +/etc/profile +/etc/bash.bashrc +/etc/skel/ +/etc/nanorc +/etc/msmtprc +/etc/msmtp_aliases +/etc/apt/sources.list +/etc/apt/sources.list.d/ +/etc/apt/listchanges.conf +/etc/apt/apt.conf.d/50unattended-upgrades +/etc/apt/apt.conf.d/20auto-upgrades +/etc/ssh/ +/etc/logwatch/ +/etc/letsencrypt/ +/etc/fail2ban/fail2ban.local +/etc/fail2ban/jail.local +/etc/fail2ban/filter.d/nextcloud.conf +/etc/fail2ban/jail.d/ +/root/.bashrc +/root/NCscripts/ +/root/.ssh/ +/etc/mysql/my.cnf +/etc/nginx/ +/etc/php/7.2/cli/php.ini +/etc/php/7.2/fpm/php-fpm.conf +/etc/php/7.2/fpm/php.ini +/etc/php/7.2/fpm/pool.d/www.conf +/etc/redis/redis.conf +/usr/share/nginx/html/ \ No newline at end of file