aports/testing/tor/tor.initd
Sam Dodrill ea8a8d1aa1 testing/tor: new aport
Anonymous network connectivity
https://www.torproject.org/

ref #1067
2013-09-03 06:10:18 +00:00

31 lines
470 B
Plaintext

#!/sbin/runscript
# Sample init.d file for alpine linux.
name=tor
daemon=/usr/bin/$name
depend() {
need net
after firewall
provide $name
}
start() {
ebegin "Starting ${name}"
start-stop-daemon --start --quiet \
--pidfile /var/run/${name}.pid \
-u ${name} \
--exec ${daemon} -- --runasdaemon 1
eend $?
}
stop() {
ebegin "Stopping ${name}"
start-stop-daemon --stop --quiet \
--pidfile /var/run/$name.pid \
--exec ${daemon}
eend $?
}