Add snapper and borgbackup for fuchsia home directory backups: Snapper Configuration: - Hourly snapshots of /home/sajenim - Retention: 24 hourly, 7 daily, 4 weekly, 12 monthly - Stored in nested .snapshots subvolume Borgbackup Onsite: - Backup to viridian over SSH (local network) - Target: ssh://viridian/srv/borg-repo/fuchsia - Hourly backups, unencrypted, deduplicated - Same retention as snapper Borgbackup Offsite: - Backup to borgbase (internet) - Target: li9kg944@li9kg944.repo.borgbase.com:repo - Daily backups, encrypted (repokey-blake2), deduplicated - Retention: 7 daily, 4 weekly, 12 monthly Explicit Home Paths (valuable user data only): - Documents, Pictures, Videos, Music, Downloads, Academics, Notes - Dotfiles: .ssh, .gnupg System Persist Data: - SSH host keys, machine-id, nixos state - Bluetooth, NetworkManager configurations Intentionally Excluded: - .config (managed declaratively via home-manager) - .repositories (cloneable from GitHub) - .cache and build artifacts Treats viridian as central backup server, maintaining 3-2-1 strategy (3 copies, 2 locations, 1 offsite). chore(viridian): remove unused inputs parameter from borgbackup offsite
22 lines
632 B
Nix
22 lines
632 B
Nix
{...}: {
|
|
# Configure snapper for automated snapshots
|
|
# Snapshots stored in nested .snapshots subvolume within home directory
|
|
services.snapper = {
|
|
configs = {
|
|
# Home directory for user sajenim
|
|
home = {
|
|
SUBVOLUME = "/home/sajenim";
|
|
ALLOW_USERS = ["sajenim"];
|
|
TIMELINE_CREATE = true;
|
|
TIMELINE_CLEANUP = true;
|
|
|
|
# Tiered retention: 24h + 7d + 4w + 12m = ~1 year of snapshots
|
|
TIMELINE_LIMIT_HOURLY = 24;
|
|
TIMELINE_LIMIT_DAILY = 7;
|
|
TIMELINE_LIMIT_WEEKLY = 4;
|
|
TIMELINE_LIMIT_MONTHLY = 12;
|
|
TIMELINE_LIMIT_YEARLY = 0;
|
|
};
|
|
};
|
|
};
|
|
}
|