# USAGE in your configuration.nix. # Update devices to match your hardware. { device ? throw "Set this to your disk device, e.g. /dev/sda", root_size , nix_size, ... }: { disko.devices = { disk = { main = { inherit device; type = "disk"; content = { type = "gpt"; partitions = { boot = { size = "1M"; type = "EF02"; # for grub MBR }; ESP = { size = "1G"; type = "EF00"; content = { type = "filesystem"; format = "vfat"; mountpoint = "/boot"; mountOptions = [ "umask=0077" ]; }; }; nix = { size = "${nix_size}"; content = { type = "filesystem"; format = "ext4"; mountpoint = "/nix"; }; }; root = { size = "${root_size}"; content = { type = "filesystem"; format = "ext4"; mountpoint = "/"; }; }; home = { size = "100%"; content = { type = "filesystem"; format = "ext4"; mountpoint = "/home"; }; }; }; }; }; }; }; }