Skip to content

Commit 4699fe2

Browse files
committed
feat(modules/mcl-disko): Legacy Boot Support
1 parent ea9ce17 commit 4699fe2

File tree

1 file changed

+22
-25
lines changed

1 file changed

+22
-25
lines changed

modules/mcl-disko/primaryZfsPartition.nix

Lines changed: 22 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -12,16 +12,9 @@
1212
device = disk;
1313
content = {
1414
type = "gpt";
15-
partitions =
16-
lib.optionals legacyBoot {
17-
"boot" = {
18-
device = "${disk}-boot";
19-
size = "1M";
20-
type = "EF02";
21-
};
22-
}
23-
// {
24-
"ESP" = {
15+
partitions = {
16+
"boot/ESP" =
17+
{
2518
device = "${disk}-part1";
2619
size = espSize;
2720
type = "EF00";
@@ -31,25 +24,29 @@
3124
mountpoint = if isSecondary then null else "/boot";
3225
mountOptions = [ "umask=0077" ];
3326
};
27+
}
28+
// lib.optionalAttrs legacyBoot {
29+
size = "100M";
30+
type = "EF02";
3431
};
35-
"zfs" = {
36-
device = "${disk}-part2";
37-
end = "-${swapSize}";
38-
type = "BF00";
39-
content = {
40-
type = "zfs";
41-
pool = "${poolName}";
42-
};
32+
"zfs" = {
33+
device = "${disk}-part2";
34+
end = "-${swapSize}";
35+
type = "BF00";
36+
content = {
37+
type = "zfs";
38+
pool = "${poolName}";
4339
};
40+
};
4441

45-
"swap" = {
46-
device = "${disk}-part3";
47-
size = swapSize;
48-
content = {
49-
type = "swap";
50-
randomEncryption = true;
51-
};
42+
"swap" = {
43+
device = "${disk}-part3";
44+
size = swapSize;
45+
content = {
46+
type = "swap";
47+
randomEncryption = true;
5248
};
5349
};
50+
};
5451
};
5552
}

0 commit comments

Comments
 (0)