summaryrefslogtreecommitdiff
path: root/os/core/bootloader.nix
diff options
context:
space:
mode:
authoradikro <adikro@disroot.org>2026-03-07 22:27:05 +0100
committeradikro <adikro@disroot.org>2026-03-07 22:27:05 +0100
commit11d05469368ecfe533c7720e7f5b624f2f8f19fc (patch)
treec666f76157b6f9158a2faa723efbf10d1d3dab03 /os/core/bootloader.nix
parentcacaadb79a73fca27bd8bbc0a33a0713d2379655 (diff)
...
Diffstat (limited to 'os/core/bootloader.nix')
-rw-r--r--os/core/bootloader.nix36
1 files changed, 0 insertions, 36 deletions
diff --git a/os/core/bootloader.nix b/os/core/bootloader.nix
index aae167e..6eca320 100644
--- a/os/core/bootloader.nix
+++ b/os/core/bootloader.nix
@@ -48,13 +48,6 @@ in
default = 0;
description = "Index of the default boot entry";
};
- signing = {
- enable = lib.mkEnableOption "GPG signing for Libreboot/GRUB";
- keyId = lib.mkOption {
- type = lib.types.str;
- description = "The GPG Key ID used to sign the boot files";
- };
- };
};
luks.enable = lib.mkEnableOption "LUKS encryption support";
@@ -104,36 +97,7 @@ in
default = cfg.grub.defaultEntry;
enableCryptodisk = cfg.luks.enable;
copyKernels = true;
-
- extraConfig = lib.mkIf cfg.grub.signing.enable ''
- set check_signatures=enforce
- terminal_input console
- terminal_output console
- '';
-
- extraInstallCommands = lib.mkIf cfg.grub.signing.enable ''
- echo "Signing with keys from ${gpgHome}"
-
- SIGN_CMD="${pkgs.gnupg}/bin/gpg --homedir ${gpgHome} --detach-sign --batch --yes --default-key ${cfg.grub.signing.keyId}"
-
- $SIGN_CMD /boot/grub/grub.cfg
-
- for f in /boot/nixos/*; do
- if [[ "$f" != *.sig ]]; then
- $SIGN_CMD "$f"
- fi
- done
- '';
};
- environment.systemPackages = lib.optional cfg.grub.signing.enable pkgs.gnupg;
})
- {
- assertions = [
- {
- assertion = cfg.grub.signing.enable -> cfg.grub.signing.keyId != "";
- message = "Bootloader signing is enabled but os.core.bootloader.grub.signing.keyId is not set.";
- }
- ];
- }
];
}