summaryrefslogtreecommitdiffstats
path: root/gentoo/files/bcfg2-server
blob: cb7848350c0acc99476d5db8fab1de2ba0f74fc9 (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
#!/sbin/runscript
#
# bcfgd - bcfg configuration daemon
#
# 

depend () {
	need net
}

start () {
	ebegin "Starting bcfgd"
	start-stop-daemon --start --quiet --pidfile /var/run/bcfgd.pid \
		--startas /usr/sbin/bcfgd.py -- --daemon=/var/run/bcfgd.pid
	eend $? "Failed to start bcfgd"
}

stop () {
	ebegin "Stopping bcfgd"
	start-stop-daemon --stop --quiet --pidfile /var/run/bcfgd.pid \
		--signal INT
	eend $? "Failed to stop bcfgd"
	[ -f /var/run/bcfgd.pid ] && rm -f /var/run/bcfgd.pid
}