nixos/nfs: Fix configuration merge
This commit is contained in:
parent
8dd1abe3fa
commit
66bbbc205d
|
@ -54,12 +54,16 @@ in
|
||||||
|
|
||||||
###### implementation
|
###### implementation
|
||||||
|
|
||||||
config = mkIf (any (fs: fs == "nfs" || fs == "nfs4") config.boot.supportedFilesystems) ({
|
config = mkIf (any (fs: fs == "nfs" || fs == "nfs4") config.boot.supportedFilesystems) {
|
||||||
|
|
||||||
services.rpcbind.enable = true;
|
services.rpcbind.enable = true;
|
||||||
|
|
||||||
system.fsPackages = [ pkgs.nfsUtils ];
|
system.fsPackages = [ pkgs.nfsUtils ];
|
||||||
|
|
||||||
|
boot.extraModprobeConfig = mkIf (cfg.lockdPort != null) ''
|
||||||
|
options lockd nlm_udpport=${toString cfg.lockdPort} nlm_tcpport=${toString cfg.lockdPort}
|
||||||
|
'';
|
||||||
|
|
||||||
boot.kernelModules = [ "sunrpc" ];
|
boot.kernelModules = [ "sunrpc" ];
|
||||||
|
|
||||||
boot.initrd.kernelModules = mkIf inInitrd [ "nfs" ];
|
boot.initrd.kernelModules = mkIf inInitrd [ "nfs" ];
|
||||||
|
@ -117,9 +121,5 @@ in
|
||||||
serviceConfig.Restart = "always";
|
serviceConfig.Restart = "always";
|
||||||
};
|
};
|
||||||
|
|
||||||
} // mkIf (cfg.lockdPort != null) {
|
};
|
||||||
boot.extraModprobeConfig = ''
|
|
||||||
options lockd nlm_udpport=${toString cfg.lockdPort} nlm_tcpport=${toString cfg.lockdPort}
|
|
||||||
'';
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user