-{ pkgs, lib, config, hostName, ... }:
+{ hostName, ... }:
{
-services.sanoid = {
- enable = true;
- templates = {
- snap = {
- autosnap = true;
- autoprune = true;
- yearly = 0;
- monthly = 3;
- daily = 31;
- hourly = 24;
- frequently = 0;
+ services.sanoid = {
+ enable = true;
+ templates = {
+ snap = {
+ autosnap = true;
+ autoprune = true;
+ yearly = 0;
+ monthly = 3;
+ daily = 31;
+ hourly = 0;
+ frequently = 0;
+ };
+ prune = {
+ autosnap = false;
+ autoprune = true;
+ yearly = 0;
+ monthly = 3;
+ daily = 31;
+ hourly = 24;
+ frequently = 0;
+ };
};
- prune = {
- autosnap = false;
- autoprune = true;
- yearly = 0;
- monthly = 3;
- daily = 31;
- hourly = 24;
- frequently = 0;
+ extraArgs = [
+ "--verbose"
+ #"--debug"
+ ];
+ datasets = {
+ "${hostName}/home/julm/work" = {
+ use_template = [ "snap" ];
+ recursive = true;
+ };
+ "${hostName}/backup/mermet" = {
+ use_template = [ "prune" ];
+ recursive = true;
+ process_children_only = true;
+ };
+ "${hostName}/backup/mermet/var/redis-rspamd" = {
+ use_template = [ "prune" ];
+ monthly = 0;
+ daily = 1;
+ hourly = 1;
+ };
+ "${hostName}/backup/mermet/var/mail" = {
+ use_template = [ "prune" ];
+ daily = 31;
+ hourly = 12;
+ };
};
};
- extraArgs = [
- "--verbose"
- #"--debug"
- ];
- datasets = {
- "${hostName}/home/julm/work" = {
- use_template = [ "snap" ];
- recursive = true;
- };
- "${hostName}/backup/mermet" = {
- use_template = [ "prune" ];
- recursive = true;
- process_children_only = true;
- };
- "${hostName}/backup/mermet/var/redis-rspamd" = {
- use_template = [ "prune" ];
- monthly = 0;
- daily = 1;
- hourly = 1;
- };
- "${hostName}/backup/mermet/var/mail" = {
- use_template = [ "prune" ];
- monthly = 0;
- daily = 31;
- hourly = 12;
- };
- };
-};
}