56ff16ada7
Features include language support, GET, POST, and HEAD methods, CGI, PHP4 , a config file (optional for every user), a mime.types file, virtual hosts, the ability to deny URLs and IPs, to run as a different user (such as nobody), serve users home directories, resume, and more. PR: ports/58290 Submitted by: Clement Laforet <sheepkiller@cultdeadsheep.org>
22 lines
379 B
Bash
22 lines
379 B
Bash
#!/bin/sh
|
|
|
|
if ! PREFIX=$(expr $0 : "\(/.*\)/etc/rc\.d/$(basename $0)\$"); then
|
|
echo "$0: Cannot determine the PREFIX" >&2
|
|
exit 1
|
|
fi
|
|
|
|
case "$1" in
|
|
start)
|
|
if [ -x ${PREFIX}/sbin/monkey ]; then
|
|
${PREFIX}/sbin/monkey -D
|
|
echo -n ' monkey'
|
|
fi
|
|
;;
|
|
stop)
|
|
kill `cat /var/run/monkey.pid`
|
|
echo -n ' monkey'
|
|
;;
|
|
*)
|
|
echo "Usage: `basename $0` {start|stop}" >&2
|
|
;;
|
|
esac
|