mirror of
https://github.com/Gerg-L/nixos.git
synced 2025-12-10 00:43:56 -05:00
disko setup for gerg-desktop Thanks Lily!
This commit is contained in:
parent
ac70f98277
commit
0fce2524d7
6 changed files with 264 additions and 247 deletions
52
systems/gerg-desktop/zfs.nix
Normal file
52
systems/gerg-desktop/zfs.nix
Normal file
|
|
@ -0,0 +1,52 @@
|
|||
_: {
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
boot = {
|
||||
zfs = {
|
||||
devNodes = "/dev/disk/by-id/";
|
||||
forceImportAll = true;
|
||||
};
|
||||
kernelPackages = config.boot.zfs.package.latestCompatibleLinuxPackages;
|
||||
kernelParams = ["nohibernate" "zfs.zfs_arc_max=17179869184"];
|
||||
supportedFilesystems = ["zfs" "vfat"];
|
||||
initrd = {
|
||||
kernelModules = ["dm_mod"];
|
||||
availableKernelModules = ["hid_generic"];
|
||||
};
|
||||
plymouth.enable = false;
|
||||
loader = {
|
||||
timeout = lib.mkForce 10;
|
||||
generationsDir.copyKernels = true;
|
||||
|
||||
#override defaults
|
||||
systemd-boot.enable = false;
|
||||
efi.canTouchEfiVariables = false;
|
||||
|
||||
grub = {
|
||||
enable = true;
|
||||
efiInstallAsRemovable = true;
|
||||
version = 2;
|
||||
copyKernels = true;
|
||||
efiSupport = true;
|
||||
zfsSupport = true;
|
||||
mirroredBoots = [
|
||||
{
|
||||
path = "/boot/efis/nvme-SHPP41-500GM_SSB4N6719101A4N0E";
|
||||
devices = ["/dev/disk/by-id/nvme-SHPP41-500GM_SSB4N6719101A4N0E"];
|
||||
}
|
||||
{
|
||||
path = "/boot/efis/nvme-SHPP41-500GM_SSB4N6719101A4N22";
|
||||
devices = ["/dev/disk/by-id/nvme-SHPP41-500GM_SSB4N6719101A4N22"];
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
systemd.services.zfs-mount.enable = false;
|
||||
services.zfs = {
|
||||
autoScrub.enable = true;
|
||||
trim.enable = true;
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue