Fix SSH in scripted initrd

Co-authored-by: Emily <vcs@emily.moe>
This commit is contained in:
r-vdp 2024-07-01 15:31:58 +02:00
parent 79d8116671
commit d1e0f30cb2
No known key found for this signature in database

View File

@ -166,6 +166,10 @@ in
UseDNS no
''}
${optionalString (!config.boot.initrd.systemd.enable) ''
SshdSessionPath /bin/sshd-session
''}
${cfg.extraConfig}
'';
in mkIf enabled {
@ -191,6 +195,7 @@ in
boot.initrd.extraUtilsCommands = mkIf (!config.boot.initrd.systemd.enable) ''
copy_bin_and_libs ${package}/bin/sshd
copy_bin_and_libs ${package}/libexec/sshd-session
cp -pv ${pkgs.glibc.out}/lib/libnss_files.so.* $out/lib
'';