summaryrefslogtreecommitdiff
path: root/net-dns/smartdns/files/smartdns.initd
blob: f6084c557daa34f38bf72600a56bae31deca0d04 (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/openrc-run
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

depend() {
	need net
}

start() {
	ebegin "Starting smartdns daemon"
	start-stop-daemon --start --exec /usr/sbin/smartdns \
		--pidfile /run/smartdns.pid \
		-- -p /run/smartdns.pid \
		${SMART_DNS_OPTS}
	eend $*
}

stop() {
	ebegin "Stopping smartdns daemon"
	start-stop-daemon --stop --exec /usr/sbin/smartdns \
		--pidfile /run/smartdns.pid
	eend $?
}