2026-05-05 15:22:34 +00:00
|
|
|
# Example to create a bios compatible gpt partition
|
|
|
|
|
{ lib, ... }:
|
|
|
|
|
{
|
|
|
|
|
disko.devices = {
|
|
|
|
|
disk = {
|
|
|
|
|
root = {
|
2026-05-07 22:41:14 +00:00
|
|
|
device = "/dev/disk/by-id/ata-SATA_SSD_18072512000554";
|
2026-05-05 15:22:34 +00:00
|
|
|
type = "disk";
|
|
|
|
|
content = {
|
|
|
|
|
type = "gpt";
|
|
|
|
|
partitions = {
|
|
|
|
|
MBR = {
|
|
|
|
|
size = "1M";
|
|
|
|
|
type = "EF02"; # for grub MBR
|
|
|
|
|
};
|
|
|
|
|
boot = {
|
|
|
|
|
size = "500M";
|
|
|
|
|
type = "EF00"; # for grub MBR
|
|
|
|
|
content = {
|
|
|
|
|
type = "filesystem";
|
|
|
|
|
format = "vfat";
|
|
|
|
|
mountpoint = "/boot";
|
|
|
|
|
mountOptions = [
|
|
|
|
|
"defaults"
|
|
|
|
|
];
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
root = {
|
|
|
|
|
size = "100%";
|
|
|
|
|
content = {
|
|
|
|
|
type = "lvm_pv";
|
|
|
|
|
vg = "pool";
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
data = {
|
2026-05-08 20:52:30 +00:00
|
|
|
device = "ata-Hitachi_HUA722020ALA331_B9HMU2WF";
|
2026-05-05 15:22:34 +00:00
|
|
|
type = "disk";
|
|
|
|
|
content = {
|
|
|
|
|
type = "gpt";
|
|
|
|
|
partitions = {
|
|
|
|
|
bigdisk = {
|
|
|
|
|
size = "100%";
|
|
|
|
|
content = {
|
|
|
|
|
type = "filesystem";
|
|
|
|
|
format = "ext4";
|
|
|
|
|
mountpoint = "/mnt/bigdisk";
|
|
|
|
|
mountOptions = [
|
|
|
|
|
"defaults"
|
|
|
|
|
];
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
lvm_vg = {
|
|
|
|
|
pool = {
|
|
|
|
|
type = "lvm_vg";
|
|
|
|
|
lvs = {
|
|
|
|
|
root = {
|
|
|
|
|
size = "100%FREE";
|
|
|
|
|
content = {
|
|
|
|
|
type = "filesystem";
|
|
|
|
|
format = "ext4";
|
|
|
|
|
mountpoint = "/";
|
|
|
|
|
mountOptions = [
|
|
|
|
|
"defaults"
|
|
|
|
|
];
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
}
|