nix-da/options/fs.nix
2024-12-15 15:39:25 +01:00

22 lines
336 B
Nix

{
config,
pkgs,
lib,
...
}:
let
inherit (lib) mkIf mkEnableOption optional;
cfg = config.modules.fs;
in
{
options.modules.fs = {
nfsEnable = mkEnableOption "nfs";
};
config = {
services.rpcbind.enable = mkIf cfg.nfsEnable true;
environment.systemPackages = optional cfg.nfsEnable pkgs.nfs-utils;
};
}