blob: 1f7203ce69be0c477db89d38ca42a746e84c1026 (
plain)
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
|
#!/bin/sh
# PROVIDE: courier_authdaemond
# REQUIRE: DAEMON mysql ldconfig
# BEFORE: mail imap
# KEYWORD: shutdown
prefix="%%PREFIX%%"
exec_prefix="${prefix}"
sysconfdir="${prefix}/etc/authlib"
sbindir="${exec_prefix}/sbin"
bindir="${exec_prefix}/bin"
authdaemonvar="%%AUTHDAEMONVAR%%"
# Define these courier_authdaemond_* variables in one of these files:
# /etc/rc.conf
# /etc/rc.conf.local
# /etc/rc.conf.d/courier_authdaemond
#
# DO NOT CHANGE THESE DEFAULT VALUES HERE
courier_authdaemond_enable=${courier_authdaemond_enable-"NO"} # Run courier-authdaemond (YES/NO).
. /etc/rc.subr
name="courier_authdaemond"
rcvar=courier_authdaemond_enable
command="${sbindir}/authdaemond"
procname="${sbindir}/courierlogger"
pidfile="${authdaemonvar}/pid"
socket="${authdaemonvar}/socket"
start_precmd="echo 'Starting ${name}.'"
start_cmd="${command} start"
stop_precmd="echo 'Stopping ${name}.'"
stop_cmd="${command} stop"
stop_postcmd="rm -f ${pidfile} ${pidfile}.lock ${socket}"
required_dirs="${authdaemonvar}"
required_files="${sysconfdir}/authdaemonrc"
load_rc_config $name
run_rc_command "$1"
|