38 lines
926 B
Nix
38 lines
926 B
Nix
|
{
|
||
|
boot.loader.grub.enableCryptodisk = true;
|
||
|
disko.devices.disk.vda = {
|
||
|
device = "/dev/vda";
|
||
|
type = "disk";
|
||
|
content = {
|
||
|
type = "gpt";
|
||
|
partitions = {
|
||
|
boot = {
|
||
|
size = "1M";
|
||
|
type = "EF02";
|
||
|
}; # partitions.boot
|
||
|
ESP = {
|
||
|
size = "500M";
|
||
|
type = "EF00";
|
||
|
content = {
|
||
|
type = "filesystem";
|
||
|
format = "vfat";
|
||
|
mountpoint = "/boot";
|
||
|
};
|
||
|
}; # ESP
|
||
|
luks = {
|
||
|
size = "100%";
|
||
|
content = {
|
||
|
type = "luks";
|
||
|
name = "crypted";
|
||
|
extraOpenArgs = [ "--allow-discards" ];
|
||
|
content = {
|
||
|
type = "filesystem";
|
||
|
format = "ext4";
|
||
|
mountpoint = "/";
|
||
|
}; # content
|
||
|
}; # content
|
||
|
}; # luks.partitions
|
||
|
}; # partitions
|
||
|
}; # content
|
||
|
}; # disko.devices.disk.vda
|
||
|
}
|