!oNSIfazDqEcwhcOjSL:matrix.org

disko

411 Members
disko - declarative disk partitioning - https://github.com/nix-community/disko113 Servers

You have reached the beginning of time (for this room).


SenderMessageTime
3 Jul 2024
@matthewcroughan:defenestrate.itmatthewcroughanI should make it possible to override this 18:28:50
4 Jul 2024
@eyjhb:eyjhb.dkeyJhb left the room.10:58:18
@philiptaron:matrix.orgPhilip Taron (UTC-8) left the room.15:46:39
@philiptaron:matrix.orgPhilip Taron (UTC-8) joined the room.15:55:30
@soispha:vhack.euBenedikt changed their display name from Soispha to Benedikt.19:11:30
@vartroc:matrix.org@vartroc:matrix.org left the room.19:17:56
5 Jul 2024
@matthewcroughan:defenestrate.itmatthewcroughanAnyone wanna help?20:36:48
@matthewcroughan:defenestrate.itmatthewcroughan blikvm-v1-disko-images> qemu-system-aarch64: failed to load "/nix/store/d2vw2hx48nphic1n4xd8y43q5vdn4lfk-kernel-modules/vmlinuz.efi" 20:36:49
@matthewcroughan:defenestrate.itmatthewcroughanwhy would that happen..20:36:56
@matthewcroughan:defenestrate.itmatthewcroughanthis is me, trying to make my PR to make the image builder kernel configurable20:41:18
@matthewcroughan:defenestrate.itmatthewcroughanIt's quite a minimal PR 20:41:41
@matthewcroughan:defenestrate.itmatthewcroughan
diff --git a/lib/make-disk-image.nix b/lib/make-disk-image.nix
index a61e937..e1f7e36 100644
--- a/lib/make-disk-image.nix
+++ b/lib/make-disk-image.nix
@@ -10,7 +10,7 @@ let
   vmTools = pkgs.vmTools.override {
     rootModules = [ "9p" "9pnet_virtio" "virtio_pci" "virtio_blk" ] ++ nixosConfig.config.disko.extraRootModules;
     kernel = pkgs.aggregateModules
-      (with nixosConfig.config.boot.kernelPackages; [ kernel ]
+      (with nixosConfig.config.disko.imageBuilderKernelPackages; [ kernel ]
         ++ lib.optional (lib.elem "zfs" nixosConfig.config.disko.extraRootModules) zfs);
   };
   cleanedConfig = diskoLib.testLib.prepareDiskoConfig nixosConfig.config diskoLib.testLib.devices;
diff --git a/module.nix b/module.nix
index 8c8fbc3..e3fde41 100644
--- a/module.nix
+++ b/module.nix
@@ -10,6 +10,15 @@ let
 in
 {
   options.disko = {
+    imageBuilderKernelPackages = lib.mkOption {
+      type = lib.types.attrs;
+      description = ''
+        the kernel used when building disk images via make-disk-image.nix.
+        Useful when the config's kernel won't boot in the image-builder.
+      '';
+      default = config.boot.kernelPackages;
+      example = lib.literalExpression "pkgs.linuxPackages_testing";
+    };
     extraRootModules = lib.mkOption {
       type = lib.types.listOf lib.types.str;
       description = ''
20:41:59

Show newer messages


Back to Room ListRoom Version: 10