all: Add allowDiscards to LUKS and enable weekly fstrim

This commit is contained in:
fleaz 2023-06-25 01:06:46 +02:00
parent 13868e6906
commit 55606b41cc
2 changed files with 4 additions and 1 deletions

View file

@ -8,6 +8,7 @@ in
boot.initrd.luks.devices."cryptroot" = { boot.initrd.luks.devices."cryptroot" = {
fallbackToPassword = true; fallbackToPassword = true;
keyFile = secretsFile; keyFile = secretsFile;
allowDiscards = true; # Allow TRIM
}; };
# copy the secret into the additional initramfs. `null` means same path # copy the secret into the additional initramfs. `null` means same path

View file

@ -47,7 +47,6 @@ in
PATH = "$PATH:/home/fleaz/bin"; PATH = "$PATH:/home/fleaz/bin";
XDG_SCREENSHOTS_DIR = "/home/fleaz/screenshots/"; XDG_SCREENSHOTS_DIR = "/home/fleaz/screenshots/";
DEFAULT_BROWSER = "${pkgs.firefox}/bin/firefox"; DEFAULT_BROWSER = "${pkgs.firefox}/bin/firefox";
}; };
console.font = consoleFont config.my.highDPI; console.font = consoleFont config.my.highDPI;
@ -58,6 +57,9 @@ in
options = "--delete-older-than 30d"; options = "--delete-older-than 30d";
}; };
# weekly trim
services.fstrim.enable = true;
networking.extraHosts = '' networking.extraHosts = ''
''; '';
} }