aboutsummaryrefslogtreecommitdiffstats
path: root/community/mautrix-telegram/mautrix-telegram.initd
blob: 93f2d0d8991c763dc87bcb7a0571d6d4c14f5cb9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/sbin/openrc-run
supervisor=supervise-daemon

name="mautrix-telegram"
description="Daemon for mautrix-telegram, the Matrix-Telegram hybrid puppeting/relaybot bridge"

: ${command_user:="mautrix-telegram:mautrix-telegram"}
: ${config:="/etc/mautrix-telegram/config.yaml"}

command="/usr/bin/mautrix-telegram"
command_args="-c $config $command_args"

depends() {
	need net
}

start_pre() {
	checkpath --file --owner "$command_user" /etc/mautrix-telegram/config.yaml
	checkpath --directory --owner "$command_user" /var/log/mautrix-telegram
}