|
|
@ -12,10 +12,13 @@ echo "Starting Backup of Nextcloud Database..." |
|
|
|
docker exec nextcloud_nc_db_1 mysqldump -u nextcloud -pnextcloud --lock-tables --databases nextcloud | |
|
|
|
docker exec nextcloud_nc_db_1 mysqldump -u nextcloud -pnextcloud --lock-tables --databases nextcloud | |
|
|
|
/usr/bin/borg create --compression zstd --stats ${BACKUP_REPO}::${BACKUP_NAME_DB} - |
|
|
|
/usr/bin/borg create --compression zstd --stats ${BACKUP_REPO}::${BACKUP_NAME_DB} - |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
echo "Backup done. Pruning Nextcloud Database..." |
|
|
|
|
|
|
|
/usr/bin/borg prune -v --list --keep-daily=7 --keep-weekly=7 --keep-monthly=10 --keep-yearly=5 -a "db_*" ${BACKUP_REPO} |
|
|
|
|
|
|
|
|
|
|
|
echo "Starting Backup of Nextcloud Uploaded Files..." |
|
|
|
echo "Starting Backup of Nextcloud Uploaded Files..." |
|
|
|
/usr/bin/borg create --compression zstd --stats ${BACKUP_REPO}::${BACKUP_NAME_DATA} /srv/docker-containers/nextcloud/nextcloud-data |
|
|
|
/usr/bin/borg create --compression zstd --stats ${BACKUP_REPO}::${BACKUP_NAME_DATA} /srv/docker-containers/nextcloud/nextcloud-data |
|
|
|
|
|
|
|
|
|
|
|
echo "Backup done. Pruning backup-repo..." |
|
|
|
echo "Backup done. Pruning Nextcloud Uploaded Files..." |
|
|
|
/usr/bin/borg prune -v --list --keep-daily=7 --keep-weekly=7 --keep-monthly=10 --keep-yearly=5 ${BACKUP_REPO} |
|
|
|
/usr/bin/borg prune -v --list --keep-daily=7 --keep-weekly=7 --keep-monthly=10 --keep-yearly=5 -a "data_*" ${BACKUP_REPO} |
|
|
|
|
|
|
|
|
|
|
|
echo "Done" |
|
|
|
echo "Done" |
|
|
|