summaryrefslogtreecommitdiff
blob: cc132d7ae9b55a34098539cb13fee7cb4b048eb7 (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
#!/sbin/runscript

depend() {
	need net
}

start() {
	rm -rf /var/tmp/distccd.pid
	ebegin "Starting distccd"
	PATH=`gcc-config --get-bin-path` /sbin/start-stop-daemon --start --quiet --startas /usr/bin/distccd \
		-c nobody --pidfile /var/tmp/distccd.pid \
		-- --pid-file /var/tmp/distccd.pid
	eend $? "Failed to Start distccd"
}

stop() {
	ebegin "Stopping distccd"
	start-stop-daemon --stop --quiet --pidfile /var/tmp/distccd.pid
	rm -rf /var/tmp/distccd.pid
	eend $? "Failed to Stop distccd"
}

restart() {
	ebegin "Restarting distccd"
	svc_stop
	svc_start
	eend $? "Failed to Restart distccd"
}