23 lines
554 B
Nix
23 lines
554 B
Nix
{ config, ... }:
|
|
{
|
|
boot.initrd.kernelModules = [ "usb_storage" ];
|
|
|
|
boot.initrd.luks.devices = {
|
|
"${config.networking.hostName}-luks0" = {
|
|
device = "/dev/disk/by-partlabel/${config.networking.hostName}-luks0";
|
|
allowDiscards = true;
|
|
keyFileSize = 32;
|
|
keyFile = "/dev/zero";
|
|
};
|
|
};
|
|
fileSystems."/" = {
|
|
device = "/dev/disk/by-label/${config.networking.hostName}-root";
|
|
fsType = "ext4";
|
|
};
|
|
fileSystems."/boot" = {
|
|
device = "/dev/disk/by-label/BOOT";
|
|
fsType = "vfat";
|
|
};
|
|
|
|
}
|