Skip to content

Commit

Permalink
netboot: Support cmdline variable from netboot.xyz
Browse files Browse the repository at this point in the history
  • Loading branch information
Enzime committed Dec 23, 2021
1 parent d8d68fe commit 7e7510d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion nixos/modules/installer/netboot/netboot.nix
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,9 @@ with lib;

system.build.netbootIpxeScript = pkgs.writeTextDir "netboot.ipxe" ''
#!ipxe
kernel ${pkgs.stdenv.hostPlatform.linux-kernel.target} init=${config.system.build.toplevel}/init initrd=initrd ${toString config.boot.kernelParams}
# Use the cmdline variable to allow the user to specify custom kernel params
# when chainloading this script from other iPXE scripts like netboot.xyz
kernel ${pkgs.stdenv.hostPlatform.linux-kernel.target} init=${config.system.build.toplevel}/init initrd=initrd ${toString config.boot.kernelParams} ''${cmdline}
initrd initrd
boot
'';
Expand Down

0 comments on commit 7e7510d

Please sign in to comment.