1
0
Fork 0
mirror of https://gitlab.alpinelinux.org/alpine/aports.git synced 2025-07-22 18:55:29 +03:00
aports/community/bitcoin/bitcoin.initd
Stuart Cardall 0c60a5fd86 community/bitcoin: revert to start-stop-daemon
* reverts the service script from using supervise-daemon back to
   using start-stop-daemon but in the modern style. This makes
   stopping of the bitcoin service reliable.

 * added a reload() function
2020-12-14 15:30:57 +00:00

24 lines
497 B
Text

#!/sbin/openrc-run
description="Bitcoin daemon"
name=bitcoind
command=/usr/bin/$name
config=/etc/bitcoin.conf
user=bitcoin
group=bitcoin
datadir=/var/lib/bitcoin
pidfile="/run/bitcoin/$RC_SVCNAME.pid"
command_user=${user}:${group}
command_args="-server -conf=${config} -datadir=${datadir} -pid=${pidfile}"
extra_started_commands="reload"
depend() {
use net
after logger firewall
}
reload() {
ebegin "Reloading ${RC_SVCNAME}"
start-stop-daemon --signal HUP --pidfile "${pidfile}"
eend $?
}