aboutsummaryrefslogtreecommitdiffstats
path: root/main/dkimproxy/dkimproxy.in.initd
blob: f7932ef467b815d3ff3c8b792c715e12d77aa2ad (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
#!/sbin/openrc-run

description="SMTP proxy that verifies signature on incoming messages"

depend() {
	need net
	after firewall
}

checkconfig() {
	if [ ! -f ${CONFIGFILE} ]; then
		eerror "Missing configuration file ${CONFIGFILE}"
		return 1
	fi
}

start() {
	checkconfig || return 1
	ebegin "Starting dkimproxy.in"
	start-stop-daemon --start -q --exec /usr/sbin/dkimproxy.in \
		--pidfile "${PIDFILE}" --make-pidfile --background \
		-- --conf_file=${CONFIGFILE} ${OPTS}
	eend $?
}


stop() {
	ebegin "Stopping dkimproxy.in"
	start-stop-daemon --stop -q --pidfile "${PIDFILE}"
	eend $?
}