NixOS-Config/modules/system/devices/boot/lanzaboote/default.nix

25 lines
504 B
Nix

{ lanzaboote, lib, config, pkgs, ... }:
{
imports = [ lanzaboote.nixosModules.lanzaboote ];
options.system.lanzaboote = {
enable = lib.mkOption {
type = lib.types.bool;
default = false;
};
};
config = lib.mkIf config.system.lanzaboote.enable {
boot = {
loader.systemd-boot.enable = lib.mkForce false;
lanzaboote = {
enable = true;
pkiBundle = "/etc/secureboot";
};
};
environment.systemPackages = with pkgs; [ sbctl ];
};
}