Add: Nextcloud Backblaze B2 backup solution - automated daily backups

- Complete backup script for native Nextcloud (MySQL + files)
- Systemd service and timer for daily automated backups at 2 AM
- Backblaze B2 integration with secure credential storage
- Incremental backup support with 30-day retention
- zstd compression for 40-70% storage reduction
- Comprehensive documentation and deployment guides
- Successfully tested with first backup: 203MB DB + 1.3GB files
- Cost-optimized: ~/bin/bash.01-0.02/month for 1.5GB data

Deployment Details:
- Installed B2 CLI via pipx
- Created backup directories at /opt/nextcloud-backup/
- Configured systemd timer for daily execution at 2 AM
- First backup verified in B2 bucket: jg-nextcloud
- Automated scheduling enabled and tested

Documentation includes:
- Deployment report with complete setup details
- Quick start guide for future deployments
- Comprehensive technical reference
- Troubleshooting procedures
- File manifest and index
This commit is contained in:
2026-04-25 18:00:07 -05:00
commit 2625cf36d2
14 changed files with 3090 additions and 0 deletions
+21
View File
@@ -0,0 +1,21 @@
[Unit]
Description=Daily Nextcloud to Backblaze B2 Backup Timer
Documentation=https://backblaze.com/b2/docs/
Requires=nextcloud-backup.service
[Timer]
# Run daily at 2 AM (adjust time zone as needed)
OnCalendar=daily
OnCalendar=*-*-* 02:00:00
# Also run on boot if we're past the scheduled time
Persistent=true
# Randomize start time by up to 15 minutes to avoid thundering herd
RandomizedDelaySec=900
# If the system is shut down during backup, continue on next startup
AccuracySec=1min
[Install]
WantedBy=timers.target