From 0dee03071a0643c3ee5820afa3c694dcef71d385 Mon Sep 17 00:00:00 2001 From: root Date: Tue, 7 Feb 2012 23:15:14 +0000 Subject: Tue Feb 7 23:15:14 UTC 2012 --- community-staging/courier-mta/pop3d-ssl.rc.d | 45 ++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 community-staging/courier-mta/pop3d-ssl.rc.d (limited to 'community-staging/courier-mta/pop3d-ssl.rc.d') diff --git a/community-staging/courier-mta/pop3d-ssl.rc.d b/community-staging/courier-mta/pop3d-ssl.rc.d new file mode 100644 index 000000000..6e7ae4e12 --- /dev/null +++ b/community-staging/courier-mta/pop3d-ssl.rc.d @@ -0,0 +1,45 @@ +#!/bin/bash + +. /etc/rc.conf +. /etc/rc.d/functions + +case "$1" in + start) + + [ -d /var/run/courier ] || mkdir -p /var/run/courier + chown courier:courier /var/run/courier + + if ck_daemon authdaemond; then + echo "ERROR: authdaemond is not running" + stat_fail + exit 1 + fi + + stat_busy "Starting Courier pop3d-ssl" + /usr/sbin/pop3d-ssl start + if [ $? -gt 0 ]; then + stat_fail + else + add_daemon pop3d-ssl + stat_done + fi + ;; + stop) + stat_busy "Stopping Courier pop3d-ssl" + /usr/sbin/pop3d-ssl stop > /dev/null + if [ $? -gt 0 ]; then + stat_fail + else + rm_daemon pop3d-ssl + stat_done + fi + ;; + restart) + $0 stop + sleep 1 + $0 start + ;; + *) + echo "usage: $0 {start|stop|restart}" +esac +exit 0 -- cgit v1.2.3-54-g00ecf