Fix boot for gamepc

This commit is contained in:
Pim Kunis 2024-11-09 10:29:18 +01:00
parent a58aa96a60
commit 3e3f589e4f

View file

@ -8,11 +8,27 @@
networking.hostName = "gamepc";
boot = {
loader = {
systemd-boot.enable = true;
efi.canTouchEfiVariables = true;
};
# boot = {
# loader = {
# systemd-boot.enable = true;
# efi.canTouchEfiVariables = true;
# };
# };
boot.loader.grub = {
enable = true;
efiSupport = true;
efiInstallAsRemovable = true;
mirroredBoots = [
{
path = "/boot0";
devices = ["nodev"];
}
{
path = "/boot1";
devices = ["nodev"];
}
];
};
disko.devices.disk = lib.genAttrs ["0" "1"] (name: {
@ -22,11 +38,13 @@
type = "gpt";
partitions = {
ESP = {
size = "500M";
type = "EF00";
size = "500M";
content = {
type = "mdraid";
name = "boot";
type = "filesystem";
format = "vfat";
mountpoint = "/boot${name}";
mountOptions = ["umask=0077"];
};
};
mdadm = {
@ -41,16 +59,16 @@
});
disko.devices.mdadm = {
boot = {
type = "mdadm";
level = 0;
# boot = {
# type = "mdadm";
# level = 1;
# metadata = "1.0";
content = {
type = "filesystem";
format = "vfat";
mountpoint = "/boot";
};
};
# content = {
# type = "filesystem";
# format = "vfat";
# mountpoint = "/boot";
# };
# };
raid0 = {
type = "mdadm";
level = 0;