@@ -131,16 +131,9 @@ let
131131 # The initrd only has to mount / or any FS marked as necessary for
132132 # booting (such as the FS containing /nix/store, or an FS needed for
133133 # mounting /, like / on a loopback).
134− #
135− # We need to guarantee that / is the first filesystem in the list so
136− # that if and when lustrateRoot is invoked, nothing else is mounted
137− fileSystems = let
138− filterNeeded = filter
139− (fs: fs.mountPoint != "/" && (fs.neededForBoot || elem fs.mountPoint [ "/nix" "/nix/store" "/var" "/var/log" "/var/lib" "/etc" ]));
140− filterRoot = filter
141− (fs: fs.mountPoint == "/");
142− allFileSystems = attrValues config.fileSystems;
143− in (filterRoot allFileSystems) ++ (filterNeeded allFileSystems);
134+ fileSystems = filter
135+ (fs: fs.neededForBoot || elem fs.mountPoint [ "/" "/nix" "/nix/store" "/var" "/var/log" "/var/lib" "/etc" ])
136+ (attrValues config.fileSystems);
144137
145138
146139 udevRules = pkgs.stdenv.mkDerivation {