Skip to content

Commit

Permalink
wip: let's see what breaks with systemd.enable
Browse files Browse the repository at this point in the history
  • Loading branch information
Mic92 committed Jun 25, 2024
1 parent dd4d166 commit 42e6be2
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions lib/tests.nix
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ let
tsp-config = tsp-generator.config testConfigBooted;
num-disks = builtins.length (lib.attrNames testConfigBooted.disko.devices.disk);

installed-system = { ... }: {
installed-system = { config, ... }: {
imports = [
(lib.optionalAttrs (testMode == "direct") tsp-config)
(lib.optionalAttrs (testMode == "module") {
Expand All @@ -101,11 +101,14 @@ let
# config for tests to make them run faster or work at all
documentation.enable = false;
hardware.enableAllFirmware = lib.mkForce false;
boot.initrd.preDeviceCommands = ''
boot.initrd.preDeviceCommands = lib.mkIf (!config.boot.initrd.systemd.enable) ''
echo -n 'secretsecret' > /tmp/secret.key
'';
boot.initrd.systemd.contents."/tmp/secret.key".text = "secretsecret";
boot.consoleLogLevel = lib.mkForce 100;
boot.loader.systemd-boot.enable = lib.mkDefault efi;

boot.initrd.systemd.enable = true;
};

installed-system-eval = eval-config {
Expand Down

0 comments on commit 42e6be2

Please sign in to comment.