From 0a7bdbb3ee75b9cc2f05c9f1b0b39cdfd70e68bc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20J=C3=A4ckel?= Date: Sun, 21 May 2023 21:12:45 +0200 Subject: [PATCH] baremetal: force import zfs pool --- modules/baremetal.nix | 38 ++++++++++++++++++++++---------------- 1 file changed, 22 insertions(+), 16 deletions(-) diff --git a/modules/baremetal.nix b/modules/baremetal.nix index b7d21ea3..adb811e7 100644 --- a/modules/baremetal.nix +++ b/modules/baremetal.nix @@ -14,23 +14,29 @@ } ]; - boot.initrd.network = { - enable = true; - ssh = { - # TODO: enable now per machine - # enable = true; - authorizedKeys = config.users.users.root.openssh.authorizedKeys.keys; - hostKeys = [ - initrdEd2219Key - initrdRsaKey - ]; - port = 4748; + boot = { + initrd.network = { + enable = true; + ssh = { + # TODO: enable now per machine + # enable = true; + authorizedKeys = config.users.users.root.openssh.authorizedKeys.keys; + hostKeys = [ + initrdEd2219Key + initrdRsaKey + ]; + port = 4748; + }; + postCommands = '' + cat < /root/.profile + cryptsetup-askpass + EOF + ''; }; - postCommands = '' - cat < /root/.profile - cryptsetup-askpass - EOF - ''; + kernelParams = [ + # "boot.shell_on_fail" + "zfs_force=1" + ]; }; environment.systemPackages = with pkgs; [