[Boot] set bootloader timeout and systemd-boot consoleMode globally

Default to max res in systemd-boot + hide boot menu if systemd-boot is
used.
This commit is contained in:
Antoine Viallon 2024-04-05 13:53:54 +02:00
parent 916430febd
commit 2fed0d81d6
Signed by: aviallon
GPG key ID: 186FC35EDEB25716

View file

@ -336,6 +336,9 @@ in {
++ optional config.aviallon.optimizations.enable customKernelPatches.zstd
;
# Hide boot menu for systemd-boot by default
loader.timeout = mkIf (!cfg.useGrub) 0;
loader.grub.enable = cfg.useGrub;
loader.grub = {
device = mkIf cfg.efi "nodev";
@ -345,7 +348,8 @@ in {
loader.systemd-boot = {
enable = cfg.efi && (!cfg.useGrub);
configurationLimit = cfg.configurationLimit;
configurationLimit = cfg.configurationLimit;
consoleMode = mkDefault "max";
extraInstallCommands = let
efiDir = config.boot.loader.efi.efiSysMountPoint;
in ''