mirror of
https://github.com/nix-community/disko
synced 2024-09-20 05:51:54 +00:00
70 lines
1.5 KiB
Nix
70 lines
1.5 KiB
Nix
|
{ disks ? [ "/dev/vdb" "/dev/vdc" ], ... }: {
|
||
|
disko.devices = {
|
||
|
disk = {
|
||
|
one = {
|
||
|
type = "disk";
|
||
|
device = builtins.elemAt disks 0;
|
||
|
content = {
|
||
|
type = "table";
|
||
|
format = "gpt";
|
||
|
partitions = [
|
||
|
{
|
||
|
name = "boot";
|
||
|
start = "0";
|
||
|
end = "100M";
|
||
|
fs-type = "fat32";
|
||
|
bootable = true;
|
||
|
content = {
|
||
|
type = "filesystem";
|
||
|
format = "vfat";
|
||
|
mountpoint = "/boot";
|
||
|
};
|
||
|
}
|
||
|
{
|
||
|
name = "primary";
|
||
|
start = "100M";
|
||
|
end = "100%";
|
||
|
content = {
|
||
|
type = "lvm_pv";
|
||
|
vg = "pool";
|
||
|
};
|
||
|
}
|
||
|
];
|
||
|
};
|
||
|
};
|
||
|
};
|
||
|
lvm_vg = {
|
||
|
pool = {
|
||
|
type = "lvm_vg";
|
||
|
lvs = {
|
||
|
aaa = {
|
||
|
size = "1M";
|
||
|
};
|
||
|
zzz = {
|
||
|
size = "1M";
|
||
|
};
|
||
|
root = {
|
||
|
size = "100M";
|
||
|
content = {
|
||
|
type = "filesystem";
|
||
|
format = "ext4";
|
||
|
mountpoint = "/";
|
||
|
mountOptions = [
|
||
|
"defaults"
|
||
|
];
|
||
|
};
|
||
|
};
|
||
|
home = {
|
||
|
size = "100%FREE";
|
||
|
content = {
|
||
|
type = "filesystem";
|
||
|
format = "ext4";
|
||
|
mountpoint = "/home";
|
||
|
};
|
||
|
};
|
||
|
};
|
||
|
};
|
||
|
};
|
||
|
};
|
||
|
}
|