diff --git a/flake.nix b/flake.nix index 8721ba1..5c57323 100644 --- a/flake.nix +++ b/flake.nix @@ -9,6 +9,7 @@ mypkgs = pkgs: { iso = import lib/gen-iso.nix lib pkgs.system; + iso-bcachefs = import lib/gen-iso-bcachefs.nix lib pkgs.system; } // (lib.mapAttrs' (name: type: { diff --git a/lib/gen-iso-bcachefs.nix b/lib/gen-iso-bcachefs.nix new file mode 100644 index 0000000..54b5d35 --- /dev/null +++ b/lib/gen-iso-bcachefs.nix @@ -0,0 +1,20 @@ +lib: +system: + +let + sys = lib.nixosSystem { + inherit system; + modules = [ + ({ modulesPath, pkgs, ... }: { + imports = [ + "${modulesPath}/installer/cd-dvd/installation-cd-minimal-new-kernel-no-zfs.nix" + ]; + boot.kernelPackages = lib.mkForce pkgs.linuxPackages_testing_bcachefs; + boot.supportedFilesystems = [ "bcachefs" ]; + isoImage.squashfsCompression = "gzip -Xcompression-level 1"; + }) + ]; + }; + +in +sys.config.system.build.isoImage