hosts: add btrfs scrub and snapper for all
This commit is contained in:
@@ -24,6 +24,29 @@
|
||||
boot.tmpOnTmpfs = true;
|
||||
zramSwap.enable = true;
|
||||
|
||||
services.btrfs.autoScrub = {
|
||||
enable = true;
|
||||
interval = "monthly";
|
||||
fileSystems = [
|
||||
"/"
|
||||
];
|
||||
};
|
||||
|
||||
services.snapper.configs = {
|
||||
home = {
|
||||
subvolume = "/home";
|
||||
extraConfig = ''
|
||||
TIMELINE_CREATE=yes
|
||||
TIMELINE_CLEANUP=yes
|
||||
TIMELINE_LIMIT_HOURLY="5"
|
||||
TIMELINE_LIMIT_DAILY="5"
|
||||
TIMELINE_LIMIT_WEEKLY="2"
|
||||
TIMELINE_LIMIT_MONTHLY="2"
|
||||
TIMELINE_LIMIT_YEARLY="0"
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-label/NIXROOT";
|
||||
fsType = "btrfs";
|
||||
|
||||
Reference in New Issue
Block a user