netmount: use want dependency to start nfsclient

add in parsing of fstab to determine if nfsclient should be automatically
started so that netmount can mount nfs without adding nfsclient
to the default runlevel

This fixes #71.
This commit is contained in:
Rick Farina (Zero_Chaos) 2015-12-08 17:02:31 -05:00 committed by William Hubbs
parent 3ef2bbfb19
commit c45313dfa9

View File

@ -6,8 +6,16 @@ description="Mounts network shares according to /etc/fstab."
depend() depend()
{ {
config /etc/fstab local opts mywant=""
use afc-client amd nfsclient autofs openvpn for opts in $(fstabinfo -o -t nfs,nfs4); do
case $opts in
noauto) ;;
*) mywant="$mywant nfsclient"; break ;;
esac
done
config /etc/fstab
want $mywant
use afc-client amd openvpn
use dns use dns
keyword -jail -prefix -systemd-nspawn -vserver -lxc keyword -jail -prefix -systemd-nspawn -vserver -lxc
} }