diff options
author | Milan Pässler <milan@petabyte.dev> | 2020-11-03 16:18:21 +0100 |
---|---|---|
committer | Milan Pässler <milan@petabyte.dev> | 2020-11-03 16:18:21 +0100 |
commit | 2a01eb6a8a1b617c53e6b7b9350197c81ca0fb36 (patch) | |
tree | b351699ea06e7b52112abab9b639711facf9592e | |
parent | b115233e9900969cc59d4859a5153c24429196ec (diff) |
grub2: add package option
-rw-r--r-- | modules/grub2/default.nix | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/modules/grub2/default.nix b/modules/grub2/default.nix index 8066d3ac5a17..08ddd1785ddd 100644 --- a/modules/grub2/default.nix +++ b/modules/grub2/default.nix @@ -80,6 +80,11 @@ in { default = "${pkgs.unifont}/share/fonts/truetype/unifont.ttf"; example = "${pkgs.dejavu_fonts}/share/fonts/truetype/DejaVuSansMono.ttf"; }; + + package = mkOption { + type = types.package; + default = pkgs.coreboot-payload-grub2; + }; }; config = mkIf cfg.enable { @@ -88,7 +93,7 @@ in { corenix.extraFiles = { ${payloadName} = { type = "payload"; - src = "${pkgs.coreboot-payload-grub2}/default_payload.elf"; + src = "${cfg.package}/default_payload.elf"; }; "font.pf2".src = (pkgs.runCommand "font.pf2" { buildInputs = with pkgs; [ grub2 ]; } |