nfs-utils/nfs-utils_env.sh
Steve Dickson 47aa7d9e2d Incorporated new upstream systemd units
Signed-off-by: Steve Dickson <steved@redhat.com>
2014-04-14 10:20:13 -04:00

34 lines
690 B
Bash

#!/bin/sh
# extract configuration from /etc/sysconfig/nfs-utils and write
# environment to /run/sysconfig/nfs-utils to be used by systemd unit
# files.
nfs_config=/etc/sysconfig/nfs
if test -r $nfs_config; then
. $nfs_config
fi
if [ "$RPCNFSDCOUNT" -gt 0 ]; then
nfsds=$RPCNFSDCOUNT
else
nfsds=8
fi
if [ -n "$RPCNFSDARGS" ]; then
nfsdargs="$RPCNFSDARGS $nfsds"
else
nfsdargs="$nfsds"
fi
mkdir -p /run/sysconfig
{
echo RPCNFSDARGS="$nfsdargs"
echo RPCMOUNTDOPTS="$RPCMOUNTDOPTS"
echo STATDARG="$STATDARG"
echo RPCIDMAPDARGS="$RPCIDMAPDARGS"
echo RPCGSSDARGS="$RPCGSSDARGS"
echo RPCSVCGSSDARGS="$RPCSVCGSSDARGS"
echo BLKMAPDARGS="$BLKMAPDARGS"
} > /run/sysconfig/nfs-utils