aboutsummaryrefslogtreecommitdiff
path: root/modules/boot/nixos
diff options
context:
space:
mode:
authorCollin Williams <96917990+bluedragon1221@users.noreply.github.com>2026-01-18 08:10:20 -0600
committerCollin Williams <96917990+bluedragon1221@users.noreply.github.com>2026-01-18 08:10:20 -0600
commitd6c4bd6d87d31a2c688fb2fcfdb0cb15d8f9163d (patch)
tree07f85b8fac540f7625f90b10ee500a1bc8116ac3 /modules/boot/nixos
parented2550a41c8429a1d2fe897deb878717c2ebc3d1 (diff)
parent43af7f28b28021932b318964a953463d8dd79372 (diff)
Merge branch 'main' into wg
Diffstat (limited to 'modules/boot/nixos')
-rw-r--r--modules/boot/nixos/default.nix50
1 files changed, 42 insertions, 8 deletions
diff --git a/modules/boot/nixos/default.nix b/modules/boot/nixos/default.nix
index 026226b..49cca5e 100644
--- a/modules/boot/nixos/default.nix
+++ b/modules/boot/nixos/default.nix
@@ -26,6 +26,37 @@ in {
efi.canTouchEfiVariables = true;
timeout = cfg.timeout; # hold space to show boot menu
};
+
+ # from hardened.nix
+ blacklistedKernelModules = [
+ # Obscure network protocols
+ "ax25"
+ "netrom"
+ "rose"
+
+ # Old or rare or insufficiently audited filesystems
+ "adfs"
+ "affs"
+ "bfs"
+ "befs"
+ "cramfs"
+ "efs"
+ # "erofs" # necessary for system.etc.overlay
+ "exofs"
+ "freevxfs"
+ "f2fs"
+ "hfs"
+ "hpfs"
+ "jfs"
+ "minix"
+ "nilfs2"
+ "ntfs"
+ "omfs"
+ "qnx4"
+ "qnx6"
+ "sysv"
+ "ufs"
+ ];
}
// (lib.optionalAttrs cfg.secureBoot.enable {
lanzaboote = {
@@ -34,14 +65,17 @@ in {
};
});
- system.etc.overlay.enable = true;
+ system.etc.overlay = {
+ enable = true;
+ mutable = true; # would love this to be false, but we're not there yet
+ };
system.nixos-init.enable = true;
- environment.systemPackages =
- (
- if cfg.secureBoot.enable
- then [pkgs.sbctl]
- else []
- )
- ++ [pkgs.efibootmgr];
+ # store journald logs in memory
+ services.journald.extraConfig = ''
+ Storage=volatile
+ RuntimeMaxUse=100M
+ '';
+
+ environment.systemPackages = [pkgs.efibootmgr] ++ lib.optional cfg.secureBoot.enable pkgs.sbctl;
}