nixdots/options/system/boot/secure-boot.nix

24 lines
636 B
Nix
Raw Normal View History

2024-07-26 23:07:07 +00:00
{lib, ...}:
with lib; let
2024-04-12 16:25:26 +00:00
inherit (lib) mkEnableOption;
2024-07-26 23:07:07 +00:00
in {
2024-04-12 18:57:52 +00:00
options.myOptions.system.boot.secure-boot = {
2024-07-26 23:07:07 +00:00
enable = mkEnableOption ''
2024-04-12 16:25:26 +00:00
secure-boot using lanzaboote.
Note that you will need to have UEFI firmware, and the rebuild
will report errors until you generate the secure boot keys with:
```shell
sudo sbctl create-keys
````
Optionally (though enabling this is pointless otherwise), you should
now enter secure-boot setup mode and enroll the keys:
```shell
sudo sbctl enroll-keys -m
```
Then reboot, and secure-boot should be enabled.
2024-07-26 23:07:07 +00:00
'';
2024-04-12 16:25:26 +00:00
};
}