Skip to content

Commit

Permalink
Add OpenRC service file (42wim#1746)
Browse files Browse the repository at this point in the history
  • Loading branch information
jan Anja committed Feb 20, 2022
1 parent 5bc18fb commit e7b3ebf
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions contrib/matterbridge.openrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#!/sbin/openrc-run
# Copyright 2021-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

command=/usr/bin/matterbridge
command_args="-conf ${MATTERBRIDGE_CONF:-/etc/matterbridge/bridge.toml} ${MATTERBRIDGE_ARGS}"
command_user="matterbridge:matterbridge"
pidfile="/run/${RC_SVCNAME}.pid"
command_background=1
output_log="/var/log/${RC_SVCNAME}.log"
error_log="${output_log}"

depend() {
need net
}

start_pre() {
checkpath -f "${output_log}" -o "${command_user}" || return 1
}

0 comments on commit e7b3ebf

Please sign in to comment.