From 6e4b0f410385bc5298762df2707e4d2f81e52eec Mon Sep 17 00:00:00 2001 From: Mark Huang Date: Mon, 24 Apr 2006 15:49:32 +0000 Subject: [PATCH] - start and stop local sendmail daemon --- plc.d/mail | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100755 plc.d/mail diff --git a/plc.d/mail b/plc.d/mail new file mode 100755 index 0000000..129bb3d --- /dev/null +++ b/plc.d/mail @@ -0,0 +1,42 @@ +#!/bin/bash +# +# priority: 250 +# +# Start local mail server. +# +# Mark Huang +# Copyright (C) 2006 The Trustees of Princeton University +# +# $Id: httpd,v 1.1 2006/04/06 21:51:59 mlhuang Exp $ +# + +# Source function library and configuration +. /etc/plc.d/functions + +case "$1" in + start) + if [ "$PLC_MAIL_ENABLED" != "1" ] ; then + exit 0 + fi + + MESSAGE=$"Starting mail server" + dialog "$MESSAGE" + + service sendmail start + check + + result "$MESSAGE" + ;; + + stop) + MESSAGE=$"Stopping mail server" + dialog "$MESSAGE" + + service sendmail stop + check + + result "$MESSAGE" + ;; +esac + +exit $ERRORS -- 2.47.0