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>
This commit is contained in:
aszlig 2014-10-22 01:50:15 +02:00
parent cb2c34f1bb
commit 23160383e3
No known key found for this signature in database
GPG key ID: D0EBD0EC8C2DC961
2 changed files with 20 additions and 0 deletions

View file

@ -364,6 +364,7 @@
./tasks/filesystems/cifs.nix
./tasks/filesystems/ext.nix
./tasks/filesystems/f2fs.nix
./tasks/filesystems/jfs.nix
./tasks/filesystems/nfs.nix
./tasks/filesystems/reiserfs.nix
./tasks/filesystems/unionfs-fuse.nix

View file

@ -0,0 +1,19 @@
{ config, lib, pkgs, ... }:
with lib;
let
inInitrd = any (fs: fs == "jfs") config.boot.initrd.supportedFilesystems;
in
{
config = mkIf (any (fs: fs == "jfs") config.boot.supportedFilesystems) {
system.fsPackages = [ pkgs.jfsutils ];
boot.initrd.kernelModules = mkIf inInitrd [ "jfs" ];
boot.initrd.extraUtilsCommands = mkIf inInitrd ''
cp -v ${pkgs.jfsutils}/sbin/fsck.jfs "$out/bin/"
'';
};
}