Revised service reload functionality

This commit is contained in:
bergware
2023-06-18 04:09:28 +02:00
parent c2065a3d93
commit 29dd4db867

View File

@@ -3,10 +3,10 @@ SERVICES="sshd avahidaemon samba rpc nfsd ntpd nginx"
job=/tmp/atjob.tmp
[[ -n $1 && -e $job ]] && exit 0
touch $job
for cmd in $SERVICES; do
if /etc/rc.d/rc.$cmd update; then
/etc/rc.d/rc.$cmd reload >/dev/null 2>&1
fi
done
touch $job
exit 0