summary refs log tree commit diff
path: root/nixos/modules/system/boot/stage-1.nix
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2014-07-28 22:31:18 +0200
committerEelco Dolstra <eelco.dolstra@logicblox.com>2014-07-28 22:31:18 +0200
commitcb7b871bd62274cca90de5f14cf50e7f4a11ba00 (patch)
treed6bec654d9b4fbb2dadd3d77a9f54ed54e3e814e /nixos/modules/system/boot/stage-1.nix
parent9bc1676e5ab6900697e7b34c50a3ca7b48f6a258 (diff)
downloadnixpkgs-cb7b871bd62274cca90de5f14cf50e7f4a11ba00.tar
nixpkgs-cb7b871bd62274cca90de5f14cf50e7f4a11ba00.tar.gz
nixpkgs-cb7b871bd62274cca90de5f14cf50e7f4a11ba00.tar.bz2
nixpkgs-cb7b871bd62274cca90de5f14cf50e7f4a11ba00.tar.lz
nixpkgs-cb7b871bd62274cca90de5f14cf50e7f4a11ba00.tar.xz
nixpkgs-cb7b871bd62274cca90de5f14cf50e7f4a11ba00.tar.zst
nixpkgs-cb7b871bd62274cca90de5f14cf50e7f4a11ba00.zip
initrd: Include filesystem support for /nix, /var etc.
Diffstat (limited to 'nixos/modules/system/boot/stage-1.nix')
-rw-r--r--nixos/modules/system/boot/stage-1.nix11
1 files changed, 11 insertions, 0 deletions
diff --git a/nixos/modules/system/boot/stage-1.nix b/nixos/modules/system/boot/stage-1.nix
index b6249b6c091..01558b8f9b2 100644
--- a/nixos/modules/system/boot/stage-1.nix
+++ b/nixos/modules/system/boot/stage-1.nix
@@ -313,6 +313,13 @@ in
       example = "xz";
     };
 
+    boot.initrd.supportedFilesystems = mkOption {
+      default = [ ];
+      example = [ "btrfs" ];
+      type = types.listOf types.string;
+      description = "Names of supported filesystem types in the initial ramdisk.";
+    };
+
     fileSystems = mkOption {
       options.neededForBoot = mkOption {
         default = false;
@@ -347,5 +354,9 @@ in
     # Prevent systemd from waiting for the /dev/root symlink.
     systemd.units."dev-root.device".text = "";
 
+    boot.initrd.supportedFilesystems =
+      map (fs: fs.fsType)
+        (filter (fs: fs.mountPoint == "/" || fs.neededForBoot) fileSystems);
+
   };
 }