fix snapper

This commit is contained in:
Tao Tien 2024-10-14 22:53:57 -07:00
parent 4edccaa438
commit b8220b11a7
3 changed files with 380 additions and 8 deletions

View file

@ -91,8 +91,8 @@
user = "tao";
dataDir = "/home/tao/sync";
configDir = "/home/tao/.config/syncthing";
overrideDevices = false;
overrideFolders = false;
overrideDevices = true;
overrideFolders = true;
openDefaultPorts = true;
settings = {
devices = {
@ -129,17 +129,30 @@
path = "/home/tao/sync";
devices = devs;
};
"work" = {
path = "/home/tao/work";
devices = devs;
};
# "work" = {
# path = "/home/tao/work";
# devices = devs;
# };
};
};
};
# nixpkgs.overlays = [
# (final: prev: {
# options.services.snapper.configs = prev.options.services.snapper.configs.overrideAttrs (old: {
# configOptions.FSTYPE = lib.mkOption {
# type = lib.types.enum ["btrfs" "bcachefs"];
# };
# });
# })
# ];
disabledModules = ["services/misc/snapper.nix"];
imports = [../extras/snapper.nix];
services.snapper.configs = {
home = {
SUBVOLUME = "/home";
FSTYPE = "bcachefs";
ALLOW_USERS = ["tao"];
TIMELINE_CREATE = true;
TIMELINE_CLEANUP = true;

View file

@ -25,8 +25,8 @@
ALLOW_USERS = ["vy"];
TIMELINE_CREATE = true;
TIMELINE_CLEANUP = true;
TIMELINE_LIMIT_HOURLY = "5";
TIMELINE_LIMIT_DAILY = "7";
TIMELINE_LIMIT_HOURLY = 5;
TIMELINE_LIMIT_DAILY = 7;
};
};
services.snapper.snapshotInterval = "*:0/5";