diff --git a/shared/modules/easy-zfs-mounts.nix b/shared/modules/easy-zfs-mounts.nix index ded1b7a..34c3bce 100644 --- a/shared/modules/easy-zfs-mounts.nix +++ b/shared/modules/easy-zfs-mounts.nix @@ -10,9 +10,15 @@ in { default = {}; }; + # config = { + # mine.zfsMounts = let + # zfsFilesystems = lib.filterAttrs (_: v: v.fsType == "zfs") config.fileSystems; + # in lib.mapAttrs' (_: v: lib.nameValuePair v.device v.mountPoint) zfsFilesystems; + # }; + + # TODO: fix this better. We just do this, so we do not rely on fileSystems, otherwise we cannot + # use this with impermanence config = { - mine.zfsMounts = let - zfsFilesystems = lib.filterAttrs (_: v: v.fsType == "zfs") config.fileSystems; - in lib.mapAttrs' (_: v: lib.nameValuePair v.device v.mountPoint) zfsFilesystems; + mine.zfsMounts = lib.mapAttrs' (n: v: lib.nameValuePair ("rpool/" + n) v.mountpoint) config.mine.disks.pools.rpool.datasets; }; }