19 lines
508 B
Nix
19 lines
508 B
Nix
{
|
|
lib,
|
|
config,
|
|
...
|
|
}: {
|
|
options.services.panoramax.impermanence.enable = lib.mkOption {
|
|
type = lib.types.bool;
|
|
default = config.services.panoramax.enable && config.storage.impermanence.enable;
|
|
};
|
|
|
|
config = lib.mkIf config.services.panoramax.enable {
|
|
storage.datasets.replicate."system/root" = {
|
|
directories."/var/lib/panoramax" = lib.mkIf config.services.panoramax.impermanence.enable {
|
|
owner.name = "panoramax";
|
|
group.name = "panoramax";
|
|
};
|
|
};
|
|
};
|
|
}
|