1
1
Fork 1
mirror of https://github.com/oddlama/nix-config.git synced 2025-10-10 23:00:39 +02:00

fix: add device overrides for new disko partlabel stuff

This commit is contained in:
oddlama 2024-03-02 16:06:15 +01:00
parent 5aad6c3a84
commit aab790065a
No known key found for this signature in database
GPG key ID: 14EFE510775FE39A
8 changed files with 110 additions and 20 deletions

View file

@ -13,9 +13,24 @@ in {
content = with lib.disko.gpt; {
type = "gpt";
partitions = {
efi = partEfi "0%" "1GiB";
swap = partSwap "1GiB" "17GiB";
"rpool_${disks.m2-ssd}" = partLuksZfs disks.m2-ssd "rpool" "17GiB" "100%";
efi =
partEfi "0%" "1GiB"
// {
# FIXME: Needed because partlabels are 💩: https://github.com/nix-community/disko/issues/551
device = "/dev/disk/by-id/${disks.m2-ssd}-part1";
};
swap =
partSwap "1GiB" "17GiB"
// {
# FIXME: Needed because partlabels are 💩: https://github.com/nix-community/disko/issues/551
device = "/dev/disk/by-id/${disks.m2-ssd}-part2";
};
"rpool_${disks.m2-ssd}" =
partLuksZfs disks.m2-ssd "rpool" "17GiB" "100%"
// {
# FIXME: Needed because partlabels are 💩: https://github.com/nix-community/disko/issues/551
device = "/dev/disk/by-id/${disks.m2-ssd}-part3";
};
};
};
};

View file

@ -13,7 +13,12 @@ in {
content = with lib.disko.gpt; {
type = "gpt";
partitions = {
"rpool_${disks.m2-ssd}" = partLuksZfs disks.m2-ssd "rpool" "0%" "100%";
"rpool_${disks.m2-ssd}" =
partLuksZfs disks.m2-ssd "rpool" "0%" "100%"
// {
# FIXME: Needed because partlabels are 💩: https://github.com/nix-community/disko/issues/551
device = "/dev/disk/by-id/${disks.m2-ssd}-part1";
};
};
};
};
@ -23,8 +28,18 @@ in {
content = with lib.disko.gpt; {
type = "gpt";
partitions = {
efi = partEfi "0%" "8GiB";
swap = partSwap "8GiB" "100%";
efi =
partEfi "0%" "8GiB"
// {
# FIXME: Needed because partlabels are 💩: https://github.com/nix-community/disko/issues/551
device = "/dev/disk/by-id/${disks.boot-ssd}-part1";
};
swap =
partSwap "8GiB" "100%"
// {
# FIXME: Needed because partlabels are 💩: https://github.com/nix-community/disko/issues/551
device = "/dev/disk/by-id/${disks.boot-ssd}-part2";
};
};
};
};

View file

@ -13,9 +13,24 @@ in {
content = with lib.disko.gpt; {
type = "gpt";
partitions = {
grub = partGrub "0%" "1MiB";
bios = partEfi "1MiB" "512MiB";
"rpool_${disks.main}" = partLuksZfs disks.main "rpool" "512MiB" "100%";
grub =
partGrub "0%" "1MiB"
// {
# FIXME: Needed because partlabels are 💩: https://github.com/nix-community/disko/issues/551
device = "/dev/disk/by-id/${disks.main}-part1";
};
bios =
partEfi "1MiB" "512MiB"
// {
# FIXME: Needed because partlabels are 💩: https://github.com/nix-community/disko/issues/551
device = "/dev/disk/by-id/${disks.main}-part2";
};
"rpool_${disks.main}" =
partLuksZfs disks.main "rpool" "512MiB" "100%"
// {
# FIXME: Needed because partlabels are 💩: https://github.com/nix-community/disko/issues/551
device = "/dev/disk/by-id/${disks.main}-part3";
};
};
};
};

View file

@ -14,8 +14,18 @@ in {
content = with lib.disko.gpt; {
type = "gpt";
partitions = {
efi = partEfi "0%" "1GiB";
"rpool_${disks.m2-ssd-1}" = partLuksZfs disks.m2-ssd-1 "rpool" "1GiB" "100%";
efi =
partEfi "0%" "1GiB"
// {
# FIXME: Needed because partlabels are 💩: https://github.com/nix-community/disko/issues/551
device = "/dev/disk/by-id/${disks.m2-ssd-1}-part1";
};
"rpool_${disks.m2-ssd-1}" =
partLuksZfs disks.m2-ssd-1 "rpool" "1GiB" "100%"
// {
# FIXME: Needed because partlabels are 💩: https://github.com/nix-community/disko/issues/551
device = "/dev/disk/by-id/${disks.m2-ssd-1}-part2";
};
};
};
};

View file

@ -13,9 +13,24 @@ in {
content = with lib.disko.gpt; {
type = "gpt";
partitions = {
efi = partEfi "0%" "1GiB";
swap = partSwap "1GiB" "17GiB";
"rpool_${disks.m2-ssd}" = partLuksZfs disks.m2-ssd "rpool" "17GiB" "100%";
efi =
partEfi "0%" "1GiB"
// {
# FIXME: Needed because partlabels are 💩: https://github.com/nix-community/disko/issues/551
device = "/dev/disk/by-id/${disks.m2-ssd}-part1";
};
swap =
partSwap "1GiB" "17GiB"
// {
# FIXME: Needed because partlabels are 💩: https://github.com/nix-community/disko/issues/551
device = "/dev/disk/by-id/${disks.m2-ssd}-part2";
};
"rpool_${disks.m2-ssd}" =
partLuksZfs disks.m2-ssd "rpool" "17GiB" "100%"
// {
# FIXME: Needed because partlabels are 💩: https://github.com/nix-community/disko/issues/551
device = "/dev/disk/by-id/${disks.m2-ssd}-part3";
};
};
};
};

View file

@ -13,9 +13,24 @@ in {
content = with lib.disko.gpt; {
type = "gpt";
partitions = {
efi = partEfi "0%" "1GiB";
swap = partSwap "1GiB" "9GiB";
"rpool_${disks.mmc}" = partLuksZfs disks.mmc "rpool" "9GiB" "100%";
efi =
partEfi "0%" "1GiB"
// {
# FIXME: Needed because partlabels are 💩: https://github.com/nix-community/disko/issues/551
device = "/dev/disk/by-id/${disks.mmc}-part1";
};
swap =
partSwap "1GiB" "9GiB"
// {
# FIXME: Needed because partlabels are 💩: https://github.com/nix-community/disko/issues/551
device = "/dev/disk/by-id/${disks.mmc}-part2";
};
"rpool_${disks.mmc}" =
partLuksZfs disks.mmc "rpool" "9GiB" "100%"
// {
# FIXME: Needed because partlabels are 💩: https://github.com/nix-community/disko/issues/551
device = "/dev/disk/by-id/${disks.mmc}-part3";
};
};
};
};