diff options
author | Nikolay Amiantov <ab@fmap.me> | 2017-02-03 20:04:25 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-02-03 20:04:25 +0300 |
commit | 230c97c944af8507128a18d58eb97e633ee561fe (patch) | |
tree | 98f2fb4498add4e03abdd60734173480cabce3b0 /nixos/modules/services/networking | |
parent | 500d48f5475fdd46773f2073cf432053602f761f (diff) | |
parent | e0e9fddf566abcaa7c71cab9c8ee698142328e6b (diff) | |
download | nixlib-230c97c944af8507128a18d58eb97e633ee561fe.tar nixlib-230c97c944af8507128a18d58eb97e633ee561fe.tar.gz nixlib-230c97c944af8507128a18d58eb97e633ee561fe.tar.bz2 nixlib-230c97c944af8507128a18d58eb97e633ee561fe.tar.lz nixlib-230c97c944af8507128a18d58eb97e633ee561fe.tar.xz nixlib-230c97c944af8507128a18d58eb97e633ee561fe.tar.zst nixlib-230c97c944af8507128a18d58eb97e633ee561fe.zip |
Merge pull request #22303 from abbradar/nfs4
NFS improvements
Diffstat (limited to 'nixos/modules/services/networking')
-rw-r--r-- | nixos/modules/services/networking/rpcbind.nix | 52 |
1 files changed, 8 insertions, 44 deletions
diff --git a/nixos/modules/services/networking/rpcbind.nix b/nixos/modules/services/networking/rpcbind.nix index eef1e8e8cd88..cddcb09054e0 100644 --- a/nixos/modules/services/networking/rpcbind.nix +++ b/nixos/modules/services/networking/rpcbind.nix @@ -2,35 +2,6 @@ with lib; -let - - netconfigFile = { - target = "netconfig"; - source = pkgs.writeText "netconfig" '' - # - # The network configuration file. This file is currently only used in - # conjunction with the TI-RPC code in the libtirpc library. - # - # Entries consist of: - # - # <network_id> <semantics> <flags> <protofamily> <protoname> \ - # <device> <nametoaddr_libs> - # - # The <device> and <nametoaddr_libs> fields are always empty in this - # implementation. - # - udp tpi_clts v inet udp - - - tcp tpi_cots_ord v inet tcp - - - udp6 tpi_clts v inet6 udp - - - tcp6 tpi_cots_ord v inet6 tcp - - - rawip tpi_raw - inet - - - - local tpi_cots_ord - loopback - - - - unix tpi_cots_ord - loopback - - - - ''; - }; - -in - { ###### interface @@ -58,25 +29,18 @@ in ###### implementation config = mkIf config.services.rpcbind.enable { - environment.systemPackages = [ pkgs.rpcbind ]; - environment.etc = [ netconfigFile ]; - - systemd.services.rpcbind = - { description = "ONC RPC Directory Service"; + systemd.packages = [ pkgs.rpcbind ]; - wantedBy = [ "multi-user.target" ]; - - requires = [ "basic.target" ]; - after = [ "basic.target" ]; - - unitConfig.DefaultDependencies = false; # don't stop during shutdown - - serviceConfig.Type = "forking"; - serviceConfig.ExecStart = "@${pkgs.rpcbind}/bin/rpcbind rpcbind"; - }; + systemd.services.rpcbind = { + wantedBy = [ "multi-user.target" ]; + }; + users.extraUsers.rpc = { + group = "nogroup"; + uid = config.ids.uids.rpc; + }; }; } |