feat: moved services over to using the new storage datasets

This commit is contained in:
Leyla Becker 2025-11-15 16:37:10 -06:00
parent 757a3892e1
commit c2701ea8f0
23 changed files with 281 additions and 606 deletions

View file

@ -8,26 +8,12 @@
default = config.services.panoramax.enable && config.storage.impermanence.enable;
};
config = lib.mkIf config.services.panoramax.enable (lib.mkMerge [
(lib.mkIf config.storage.zfs.enable (lib.mkMerge [
{
# TODO: configure impermanence for panoramax data
# This would typically include directories like:
# - /var/lib/panoramax
# - panoramax storage directories
# - any cache or temporary directories that need to persist
}
(lib.mkIf (!config.services.panoramax.impermanence.enable) {
# TODO: placeholder to configure a unique dataset for this service
})
(lib.mkIf config.services.panoramax.impermanence.enable {
storage.impermanence.datasets."persist/replicate/system/root" = {
directories."/var/lib/panoramax" = {
owner.name = "panoramax";
group.name = "panoramax";
};
};
})
]))
]);
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";
};
};
};
}