|
127 | 127 |
|
128 | 128 | ${lib.concatMapStringsSep "\n" mkMount ( |
129 | 129 | lib.filter (lib.getAttr "neededForBoot") ( |
130 | | - lib.filter (fs: !lib.elem fs.fsType [ "luks" "lvm" ]) (lib.attrValues config.fileSystems) |
| 130 | + lib.filter ( |
| 131 | + fs: |
| 132 | + !lib.elem fs.fsType [ |
| 133 | + "luks" |
| 134 | + "lvm" |
| 135 | + ] |
| 136 | + ) (lib.attrValues config.fileSystems) |
131 | 137 | ) |
132 | 138 | )} |
133 | 139 | ''; |
|
190 | 196 | task [S] name:fs-import tty:@console \ |
191 | 197 | ${lib.optionalString config.services.mdevd.enable "<run/coldplug/success>"} \ |
192 | 198 | ${lib.optionalString config.services.udev.enable "<run/udevadm:5/success>"} \ |
| 199 | + ${lib.optionalString config.services.keventd.enable "<service/keventd/ready>"} \ |
193 | 200 | finix-fs-import |
194 | 201 |
|
195 | 202 | task [S] name:mount-all <task/fs-import/success> finix-mount-all |
|
202 | 209 | service [S] <!> notify:s6 /bin/udevd --ready-notify=%n |
203 | 210 | ''} |
204 | 211 |
|
| 212 | + ${lib.optionalString config.services.keventd.enable '' |
| 213 | + service [S] name:keventd notify:pid <!> keventd -n -c |
| 214 | + ''} |
| 215 | +
|
205 | 216 | run [1] finix-switch-root |
206 | 217 | ''; |
207 | 218 | } |
|
222 | 233 | } |
223 | 234 | { |
224 | 235 | target = "/etc/group"; |
225 | | - source = pkgs.writeText "group" '' |
226 | | - root:x:0: |
227 | | - ''; |
| 236 | + source = pkgs.writeText "group" ( |
| 237 | + lib.concatStringsSep "\n" ( |
| 238 | + lib.concatMap (g: lib.optionals (g.gid != null) [ "${g.name}:x:${toString g.gid}" ]) ( |
| 239 | + lib.attrValues config.users.groups |
| 240 | + ) |
| 241 | + ) |
| 242 | + ); |
228 | 243 | } |
229 | 244 | { |
230 | 245 | target = "/etc/shadow"; |
|
245 | 260 | { source = "${config.finit.package}/lib/finit/rescue.conf"; } |
246 | 261 | { source = "${config.finit.package}/lib/finit/tmpfiles.d"; } |
247 | 262 | { source = "${config.finit.package}/lib/tmpfiles.d"; } |
| 263 | + ] |
| 264 | + ++ lib.optionals config.services.keventd.enable [ |
| 265 | + { |
| 266 | + target = "/etc/udev/rules.d"; # keventd reads /etc - avoids collision |
| 267 | + source = "${config.finit.package}/lib/udev/rules.d"; |
| 268 | + } |
248 | 269 | ]; |
249 | 270 | }; |
250 | 271 | } |
0 commit comments