Author: eelco
Date: Thu Mar 22 12:24:23 2012
New Revision: 33356
URL: https://nixos.org/websvn/nix/?rev=33356&sc=1
Log:
* Remove the ‘services.nfs.client.enable’ flag; use
‘boot.supportedFilesystems = [ "nfs" ]’ if needed.
Modified:
nixos/trunk/modules/services/network-filesystems/nfsd.nix
nixos/trunk/modules/tasks/filesystems.nix
nixos/trunk/modules/tasks/filesystems/nfs.nix
Modified: nixos/trunk/modules/services/network-filesystems/nfsd.nix
==============================================================================
--- nixos/trunk/modules/services/network-filesystems/nfsd.nix Thu Mar 22
12:22:44 2012 (r33355)
+++ nixos/trunk/modules/services/network-filesystems/nfsd.nix Thu Mar 22
12:24:23 2012 (r33356)
@@ -69,7 +69,7 @@
services.rpcbind.enable = true;
- services.nfs.client.enable = true; # needed for statd and idmapd
+ boot.supportedFilesystems = [ "nfs" ]; # needed for statd and idmapd
environment.systemPackages = [ pkgs.nfsUtils ];
Modified: nixos/trunk/modules/tasks/filesystems.nix
==============================================================================
--- nixos/trunk/modules/tasks/filesystems.nix Thu Mar 22 12:22:44 2012
(r33355)
+++ nixos/trunk/modules/tasks/filesystems.nix Thu Mar 22 12:24:23 2012
(r33356)
@@ -184,12 +184,6 @@
''
# Ensure that this job is restarted when fstab changed:
# ${fstab}
-
- ${optionalString config.services.nfs.client.enable ''
- ensure statd || true
- ensure idmapd || true
- ''}
-
echo "mounting filesystems..."
'';
Modified: nixos/trunk/modules/tasks/filesystems/nfs.nix
==============================================================================
--- nixos/trunk/modules/tasks/filesystems/nfs.nix Thu Mar 22 12:22:44
2012 (r33355)
+++ nixos/trunk/modules/tasks/filesystems/nfs.nix Thu Mar 22 12:24:23
2012 (r33356)
@@ -31,23 +31,9 @@
{
- ###### interface
-
- options = {
-
- services.nfs.client.enable = mkOption {
- default = any (fs: fs.fsType == "nfs" || fs.fsType == "nfs4")
config.fileSystems;
- description = ''
- Whether to enable support for mounting NFS filesystems.
- '';
- };
-
- };
-
-
###### implementation
- config = mkIf config.services.nfs.client.enable {
+ config = mkIf (any (fs: fs == "nfs" || fs == "nfs4")
config.boot.supportedFilesystems) {
services.rpcbind.enable = true;
@@ -63,6 +49,13 @@
environment.etc = singleton idmapdConfFile;
+ # Ensure that statd and idmapd are started before mountall.
+ jobs.mountall.preStart =
+ ''
+ ensure statd || true
+ ensure idmapd || true
+ '';
+
jobs.statd =
{ description = "Kernel NFS server - Network Status Monitor";
_______________________________________________
nix-commits mailing list
[email protected]
http://lists.science.uu.nl/mailman/listinfo/nix-commits