summaryrefslogtreecommitdiff
blob: 8b18727d19cf66d862678be0f413a3540353fa78 (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
#!/sbin/runscript
# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

depend() {
	need net
	use logger
	after domainname
}

start() {
	if [[ "`cat /var/lib/vice/hostname`" != "`cat /var/lib/vice/db/scm`" ]] ; then
		CHK="-chk"
	fi

	ebegin "Starting ${SVCNAME}"
	start-stop-daemon --start --background \
		--pidfile /var/lib/vice/auth2/pid --make-pidfile \
		--exec /usr/sbin/auth2 -- ${CHK}
	eend $?
}

stop() {
	ebegin "Stopping ${SVCNAME}"
	start-stop-daemon --stop \
		--pidfile /var/lib/vice/auth2/pid \
		--name auth2
	eend $?
}