blob: 9a0f7848a591a6d87d8ded1fa974b71304895d5c (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
|
#!/bin/sh
#
# $FreeBSD$
#
# PROVIDE: mail
# REQUIRE: LOGIN
# KEYWORD: shutdown
#
# Add the following lines to /etc/rc.conf to enable zmailer:
#
#zmailer_enable="YES"
#
. /etc/rc.subr
name=zmailer
rcvar=`set_rcvar`
command=%%PREFIX%%/sbin/zmailer
required_files=%%PREFIX%%/etc/zmailer/mail.conf
start_precmd=start_precmd
start_cmd=start_cmd
stop_cmd=stop_cmd
start_precmd()
{
case $sendmail_enable in
[Yy][Ee][Ss]|[Tt][Rr][Uu][Ee]|[Oo][Nn]|1)
warn "sendmail_enable should be set to NONE"
;;
[Nn][Oo]|[Ff][Aa][Ll][Ss][Ee]|[Oo][Ff][Ff]|0)
case $sendmail_submit_enable in
[Yy][Ee][Ss]|[Tt][Rr][Uu][Ee]|[Oo][Nn]|1)
warn "sendmail_submit_enable should be set to NO"
;;
esac
;;
[Nn][Oo][Nn][Ee])
;;
esac
}
start_cmd()
{
$command start
}
stop_cmd()
{
$command stop
}
# set defaults
zmailer_enable=${zmailer_enable:-"NO"}
load_rc_config $name
run_rc_command "$1"
|