aboutsummaryrefslogtreecommitdiffstats
path: root/main/mini_httpd/mini_httpd.initd
blob: b55340ac5d9131e197c9f3c1a1d59142ad5ea29b (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
#!/sbin/runscript
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/www-servers/mini_httpd/files/mini_httpd.init,v 1.2 2007/08/26 21:20:21 bangert Exp $

pidfile=/var/run/mini_httpd/${SVCNAME}.pid

depend() {
	need net
}

start() {
	ebegin "Starting $SVCNAME"
	start-stop-daemon --quiet --start --exec /usr/sbin/mini_httpd \
		--pidfile $pidfile -- -i $pidfile \
		${MINI_HTTPD_OPTS:--C /etc/${SVCNAME}.conf -l /var/log/mini_httpd/${SVCNAME}.log}
	eend $?
}

stop() {
	ebegin "Stopping $SVCNAME"
	start-stop-daemon --quiet --stop --pidfile $pidfile
	eend $?
}