feat(hosts): update disko config.

This commit is contained in:
CronyAkatsuki 2025-05-17 19:02:55 +02:00
parent 35a1ef77cc
commit 5aa2be1ea8

View file

@ -1,49 +1,52 @@
{lib, ...}: { {
disko.devices = { disko.devices = {
disk.disk1 = { disk = {
device = lib.mkDefault "/dev/vda"; main = {
type = "disk"; type = "disk";
device = "/dev/nvme0n1";
content = { content = {
type = "gpt"; type = "gpt";
partitions = { partitions = {
boot = { ESP = {
name = "boot"; size = "512M";
size = "1M";
type = "EF02";
};
esp = {
name = "ESP";
size = "500M";
type = "EF00"; type = "EF00";
content = { content = {
type = "filesystem"; type = "filesystem";
format = "vfat"; format = "vfat";
mountpoint = "/boot"; mountpoint = "/boot";
mountOptions = ["umask=0077"];
}; };
}; };
root = { luks = {
name = "root";
size = "100%"; size = "100%";
content = { content = {
type = "lvm_pv"; type = "luks";
vg = "pool"; name = "crypted";
}; settings.allowDiscards = true;
}; passwordFile = "/tmp/secret.key";
};
};
};
lvm_vg = {
pool = {
type = "lvm_vg";
lvs = {
root = {
size = "100%FREE";
content = { content = {
type = "filesystem"; type = "btrfs";
format = "ext4"; extraArgs = ["-f"];
subvolumes = {
"@" = {
mountpoint = "/"; mountpoint = "/";
mountOptions = [ mountOptions = [
"defaults" "compress=zstd"
"noatime"
];
};
"@home" = {
mountpoint = "/home";
mountOptions = [
"compress=zstd"
"noatime"
];
};
"@nix" = {
mountpoint = "/nix";
mountOptions = [
"compress=zstd"
"noatime"
]; ];
}; };
}; };
@ -51,4 +54,8 @@
}; };
}; };
}; };
};
};
};
};
} }