From 7fd37352038c2400a59062e66fbd68a6ec2eedbe Mon Sep 17 00:00:00 2001 From: Michael Hoang Date: Fri, 1 Aug 2025 14:06:13 +1000 Subject: [PATCH] iso-image: ensure `boot.loader.grub.enable` is disabled by default We use `mkImageMediaOverride` to ensure that GRUB is actually disabled if a user enables it using the default priority but still allows them to enable it using `mkForce`. --- nixos/modules/installer/cd-dvd/iso-image.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nixos/modules/installer/cd-dvd/iso-image.nix b/nixos/modules/installer/cd-dvd/iso-image.nix index 35afdc3a3f76..e49159c5964f 100644 --- a/nixos/modules/installer/cd-dvd/iso-image.nix +++ b/nixos/modules/installer/cd-dvd/iso-image.nix @@ -865,7 +865,7 @@ in # Don't build the GRUB menu builder script, since we don't need it # here and it causes a cyclic dependency. - boot.loader.grub.enable = false; + boot.loader.grub.enable = lib.mkImageMediaOverride false; environment.systemPackages = [ grubPkgs.grub2