AI given structure

This commit is contained in:
1jamesthompson1
2026-03-23 16:06:42 +13:00
commit 716baafbc1
35 changed files with 1570 additions and 0 deletions

24
backup.sh Executable file
View File

@@ -0,0 +1,24 @@
#!/bin/bash
# Backup all persistent service data using Restic
set -euo pipefail
# Load environment
source .env
export RESTIC_REPOSITORY=/mnt/storage/backups
export RESTIC_PASSWORD_FILE=/root/.restic_pass
SERVICES=(gitea nextcloud qbittorrent jellyfin devbox obsidian traefik)
for svc in "${SERVICES[@]}"; do
target="${STORAGE_PATH}/${svc}"
if [ -d "$target" ]; then
echo "Backing up $svc..."
restic backup "$target" --tag "$svc"
else
echo "Skipping $svc - directory $target not found"
fi
done
echo "Backup complete."
restic snapshots --latest 5