SwordArMor-gentoo-overlay/net-im/mautrix-signal/files/mautrix-signal.initd

26 lines
702 B
Plaintext
Raw Normal View History

#!/sbin/openrc-run
# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
name="mautrix-signal daemon"
description="A Matrix-Signal puppeting bridge"
module="mautrix_signal"
pidfile="/run/${RC_SVCNAME}.pid"
command="/usr/bin/mautrix-signal"
command_args="-c /etc/mautrix/${module}.yaml -r /var/lib/mautrix/signal/registration.yaml"
command_background=true
command_user="mautrix-signal:mautrix"
output_log="/var/log/mautrix/signal/daemon.log"
error_log="/var/log/mautrix/signal/daemon.log"
depend() {
need net
}
start_pre() {
checkpath -d -m 0755 -o "$command_user" /var/lib/mautrix/signal
checkpath -f -m 0644 -o "$command_user" "$output_log"
}