#!/bin/sh

if [ ! -f %%PREFIX%%/sbin/rbl-milter ]
then
	echo "rbl-milter not installed"
	exit 0;
fi

case $1 in
start)
	%%PREFIX%%/sbin/rbl-milter -l -r -p local:/var/run/rbl-milter -d relays.ordb.org \ 
	&& echo -n " rbl-milter" \
	|| echo " rbl-milter FAILED TO START"
	;;
stop)
	killall rbl-milter && echo -n " rbl-milter"
	;;
restart)
        $0 stop
        $0 start
        ;;
*)
        echo "Usage: `basename $0` {start|stop}" >&2
        exit 64
        ;;
esac

exit 0


syntax highlighted by Code2HTML, v. 0.9.1