nixos: Add a filesystem module for JFS.
I'm not using JFS, but this is to mainly make jfsutils available if you
have defined a JFS filesystem in your configuration.
Signed-off-by: aszlig <aszlig@redmoonstudios.org>
commit23160383e3d499fea96ff0feeb918e3c65a44d44
authoraszlig <aszlig@redmoonstudios.org>
dateWed 22 Oct 2014, 01:50 (12 years ago)
parentcb2c34f
nixos/modules/module-list.nix+1
@@ -364,6 +364,7 @@
364364 ./tasks/filesystems/cifs.nix
365365 ./tasks/filesystems/ext.nix
366366 ./tasks/filesystems/f2fs.nix
367+ ./tasks/filesystems/jfs.nix
367368 ./tasks/filesystems/nfs.nix
368369 ./tasks/filesystems/reiserfs.nix
369370 ./tasks/filesystems/unionfs-fuse.nix
nixos/modules/tasks/filesystems/jfs.nixnew file+19
@@ -0,0 +1,19 @@
1+{ config, lib, pkgs, ... }:
2+
3+with lib;
4+
5+let
6+ inInitrd = any (fs: fs == "jfs") config.boot.initrd.supportedFilesystems;
7+in
8+{
9+ config = mkIf (any (fs: fs == "jfs") config.boot.supportedFilesystems) {
10+
11+ system.fsPackages = [ pkgs.jfsutils ];
12+
13+ boot.initrd.kernelModules = mkIf inInitrd [ "jfs" ];
14+
15+ boot.initrd.extraUtilsCommands = mkIf inInitrd ''
16+ cp -v ${pkgs.jfsutils}/sbin/fsck.jfs "$out/bin/"
17+ '';
18+ };
19+}