#!/bin/sh
# Begin /etc/init.d/

#
# Include the functions declared in the /etc/rc.d/functions file
source /etc/rc.d/functions

# path to binary
ROOT="/usr/sbin"
# name of binary to run
APP="sendmail"
#runtime options
OPT="-bd -q15m"
#server name
SERVER="Sendmail"

case "$1" in
        start)
                echo -n "Starting $SERVER..........."
                loadproc $ROOT/$APP $OPT
                ;;

        stop)
                echo -n "Stopping $SERVER..........."
                killproc $ROOT/$APP
                ;;

        reload)
                echo -n "Reloading $SERVER.........."
                reloadproc $ROOT/$APP
                ;;

        restart)
                $0 stop
                /bin/sleep 1
                $0 start
                ;;

        status)
                statusproc $APP
                ;;

        *)
                echo "Usage: $0 {start|stop|reload|restart|status}"
                exit 1
        ;;

esac

# End /etc/init.d/
