net-p2p/trezord-go: add openrc init script

Package-Manager: Portage-2.3.99, Repoman-2.3.23
Signed-off-by: Andreas Zuber <a.zuber@gmx.ch>
Signed-off-by: Michael Egger <egger.m@protonmail.com>
This commit is contained in:
Andreas Zuber
2020-07-09 19:29:07 +02:00
committed by Michael Egger
parent 67d786df89
commit 3147f44d97
2 changed files with 13 additions and 0 deletions

View File

@@ -0,0 +1,9 @@
#!/sbin/openrc-run
# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
command="/usr/bin/trezord"
pidfile="/run/${RC_SVCNAME}.pid"
command_args="-l /var/log/trezord/trezord.log"
command_user="trezord"
command_background=true

View File

@@ -24,6 +24,10 @@ DEPEND="
src_install() {
newbin trezord-go trezord
newinitd "${FILESDIR}/trezord-openrc.sh" trezord
keepdir /var/log/trezord
fowners trezord:root /var/log/trezord
use systemd && systemd_dounit src/github.com/trezor/trezord-go/release/linux/trezord.service
use udev && udev_dorules src/github.com/trezor/trezord-go/release/linux/trezor.rules
}