openbsd-ports/net/samba/pkg/samba.rc

19 lines
398 B
Plaintext
Raw Normal View History

#!/bin/sh
#
2011-07-07 22:14:58 -04:00
# $OpenBSD: samba.rc,v 1.3 2011/07/08 02:14:59 ajacoutot Exp $
# "meta" script running the following rc.d(8) scripts with the given argument
2011-07-07 22:14:58 -04:00
_pkg_scripts="smbd nmbd"
2011-07-07 22:14:58 -04:00
set -A _s -- ${_pkg_scripts}
if [ "$1" = stop ]; then
2011-07-07 22:14:58 -04:00
i=$(echo ${_pkg_scripts} | wc -w)
while [ $i -ne 0 ]; do
i=$((i-1))
/etc/rc.d/${_s[$i]} $1
done
else
2011-07-07 22:14:58 -04:00
for i in ${_pkg_scripts}; do /etc/rc.d/$i $1; done
fi