{ lib, config, ... }: { # disko.devices.disk.main.device = "/dev/vda"; options.internal.disko.default.enable = lib.mkEnableOption ""; config = lib.mkIf config.internal.disko.default.enable { boot.loader.grub.efiSupport = lib.mkDefault true; boot.loader.grub.efiInstallAsRemovable = lib.mkDefault true; disko.devices = { disk = { "main" = { # suffix is to prevent disk name collisions name = "main-" + config.networking.hostName; type = "disk"; # device = ; content = { type = "gpt"; partitions = { "boot" = { size = "1M"; type = "EF02"; # for grub MBR priority = 1; }; "ESP" = { size = "512M"; type = "EF00"; content = { type = "filesystem"; format = "vfat"; mountpoint = "/boot"; mountOptions = [ "nofail" ]; }; }; "root" = { size = "100%"; content = { type = "filesystem"; format = "ext4"; mountpoint = "/"; }; }; }; }; }; }; }; }; }