liminix

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit 63a89f7d0de5fdd135801bb0bc3711cd8434b27f
parent 07eb3d66daefffe6dc1265cbc680f3ef2f9329db
Author: Daniel Barlow <dan@telent.net>
Date:   Mon, 10 Apr 2023 19:07:27 +0100

add config.boot.initramfs.enable

Diffstat:
Mmodules/initramfs.nix | 10++++++++--
Mmodules/jffs2.nix | 1+
2 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/modules/initramfs.nix b/modules/initramfs.nix @@ -5,11 +5,17 @@ , ... }: let -# inherit (lib) mkOption types concatStringsSep; + inherit (lib) mkEnableOption mkIf; inherit (pkgs) runCommand callPackage writeText; in { - config = { + options = { + boot.initramfs = { + enable = mkEnableOption "enable initramfs"; + default = false; + }; + }; + config = mkIf config.boot.initramfs.enable { kernel.config.BLK_DEV_INITRD = "y"; outputs = { diff --git a/modules/jffs2.nix b/modules/jffs2.nix @@ -12,6 +12,7 @@ in ]; config = { kernel.config.JFFS2_FS = "y"; + boot.initramfs.enable = true; outputs = rec { systemConfiguration = pkgs.pkgsBuildBuild.systemconfig config.filesystem.contents;