1 import ./make-test-python.nix ({ lib, pkgs, ... }: {
2 name = "systemd-initrd-modprobe";
4 nodes.machine = { pkgs, ... }: {
5 boot.initrd.systemd.enable = true;
6 boot.initrd.kernelModules = [ "loop" ]; # Load module in initrd.
7 boot.extraModprobeConfig = ''
8 options loop max_loop=42
13 machine.wait_for_unit("multi-user.target")
14 max_loop = machine.succeed("cat /sys/module/loop/parameters/max_loop")
15 assert int(max_loop) == 42, "Parameter should be respected for initrd kernel modules"