Each generation stores a kernel and an initrd on the EFI system partition, and this host runs a large third-party kernel, so 512 MiB holds only about seven. An exhausted partition fails at bootloader installation, after the build has already succeeded. The partition cannot grow in place: it sits first on the disk with the encrypted container immediately behind it, and an encrypted volume's start offset cannot move without rewriting its whole payload. Only an install applies this layout, so the change takes effect at the next reimage and does nothing to the running machine until then. Record that a flake only sees git-tracked files, which cost an evaluation earlier, and correct the git identity gotcha that a hand-written gitconfig had made false.
63 lines
1.7 KiB
Nix
63 lines
1.7 KiB
Nix
{ ... }:
|
|
# neogaia's disk layout for disko: one NVMe disk, GPT, with an EFI system
|
|
# partition and a LUKS container holding btrfs subvolumes. No swap partition;
|
|
# swap is zram. disko derives `fileSystems` and `boot.initrd.luks.devices` from this.
|
|
{
|
|
disko.devices.disk.main = {
|
|
type = "disk";
|
|
device = "/dev/nvme0n1";
|
|
content = {
|
|
type = "gpt";
|
|
partitions = {
|
|
ESP = {
|
|
# Each generation stores a kernel and initrd here and the CachyOS
|
|
# kernel is large; an exhausted partition fails bootloader installs.
|
|
size = "2G";
|
|
type = "EF00";
|
|
content = {
|
|
type = "filesystem";
|
|
format = "vfat";
|
|
mountpoint = "/boot";
|
|
mountOptions = [ "umask=0077" ];
|
|
};
|
|
};
|
|
luks = {
|
|
size = "100%";
|
|
content = {
|
|
type = "luks";
|
|
name = "cryptroot";
|
|
settings.allowDiscards = true;
|
|
content = {
|
|
type = "btrfs";
|
|
extraArgs = [ "-f" ];
|
|
subvolumes = {
|
|
"@root" = {
|
|
mountpoint = "/";
|
|
mountOptions = [
|
|
"compress=zstd"
|
|
"noatime"
|
|
];
|
|
};
|
|
"@home" = {
|
|
mountpoint = "/home";
|
|
mountOptions = [
|
|
"compress=zstd"
|
|
"noatime"
|
|
];
|
|
};
|
|
"@nix" = {
|
|
mountpoint = "/nix";
|
|
mountOptions = [
|
|
"compress=zstd"
|
|
"noatime"
|
|
];
|
|
};
|
|
};
|
|
};
|
|
};
|
|
};
|
|
};
|
|
};
|
|
};
|
|
}
|