From a5849260f9c158a89a142a8afe15960870351cc0 Mon Sep 17 00:00:00 2001 From: "Andrew J. Hesford" Date: Sun, 11 Dec 2022 10:17:05 -0500 Subject: [PATCH] nfs-utils: support configuration file in nfs-server service --- srcpkgs/nfs-utils/files/nfs-server/run | 19 ++++++------------- srcpkgs/nfs-utils/template | 2 +- 2 files changed, 7 insertions(+), 14 deletions(-) diff --git a/srcpkgs/nfs-utils/files/nfs-server/run b/srcpkgs/nfs-utils/files/nfs-server/run index fcfa3defe80..74ce0477fb7 100755 --- a/srcpkgs/nfs-utils/files/nfs-server/run +++ b/srcpkgs/nfs-utils/files/nfs-server/run @@ -3,18 +3,11 @@ # Make sure the statd service is running. sv check statd >/dev/null || exit 1 -# Uncomment and add daemons for kerberos support. -#sv check rpcidmapd >/dev/null || exit 1 -#sv check rpcsvgssd >/dev/null || exit 1 +# This was probably only used correctly to set PROCESSES +[ -r /etc/conf.d/nfs-server.conf ] && . /etc/conf.d/nfs-server.conf -# Uncomment and add daemon for pNFS support. -#sv check rpcblkmapd >/dev/null || exit 1 - -# Get the nfs service parameters from the LFS standard file -# this sets some envars. -if [ -e /etc/conf.d/nfs-server.conf ]; then - . /etc/conf.d/nfs-server.conf -fi +# Settings in ./conf should be preferred over /etc/conf.d/nfs-server.conf +[ -r ./conf ] && . ./conf # Check/mount rpc_pipefs (loads sunrpc kernel module) if ! mountpoint -q /var/lib/nfs/rpc_pipefs; then @@ -27,8 +20,8 @@ if ! mountpoint -q /proc/fs/nfsd; then fi exportfs -ra > /dev/null || exit 1 -rpc.nfsd -- ${PROCESSES:=4} || exit 1 +rpc.nfsd ${NFSD_OPTS} -- ${PROCESSES:=4} || exit 1 sm-notify -exec rpc.mountd --foreground +exec rpc.mountd ${MOUNTD_OPTS} --foreground diff --git a/srcpkgs/nfs-utils/template b/srcpkgs/nfs-utils/template index 10e72d3054c..f1ee979213f 100644 --- a/srcpkgs/nfs-utils/template +++ b/srcpkgs/nfs-utils/template @@ -1,7 +1,7 @@ # Template file for 'nfs-utils' pkgname=nfs-utils version=2.5.4 -revision=1 +revision=2 build_style=gnu-configure configure_args="--with-statduser=nobody --enable-gss --enable-nfsv4 --with-statedir=/var/lib/nfs --enable-libmount-mount --enable-svcgss