#!/bin/sh
# Start/stop/restart the system logging daemons.
#
# Written for Slackware Linux by Patrick J. Volkerding <volkerdi@slackware.com>.

postfix_start() {
  if [ -x /usr/sbin/postfix ]; then
    /usr/sbin/postfix start
  fi
}

postfix_stop() {
  /usr/sbin/postfix stop
}

postfix_restart() {
  /usr/sbin/postfix stop
  sleep 1
  /usr/sbin/postfix start
}

case "$1" in
'start')
  postfix_start
  ;;
'stop')
  postfix_stop
  ;;
'restart')
  postfix_restart
  ;;
*)
  echo "usage $0 start|stop|restart"
esac
