aboutsummaryrefslogtreecommitdiffstats
path: root/testing/spreed-webrtc/spreed-webrtc.initd
diff options
context:
space:
mode:
Diffstat (limited to 'testing/spreed-webrtc/spreed-webrtc.initd')
-rw-r--r--testing/spreed-webrtc/spreed-webrtc.initd21
1 files changed, 21 insertions, 0 deletions
diff --git a/testing/spreed-webrtc/spreed-webrtc.initd b/testing/spreed-webrtc/spreed-webrtc.initd
new file mode 100644
index 0000000000..5ab0efd22b
--- /dev/null
+++ b/testing/spreed-webrtc/spreed-webrtc.initd
@@ -0,0 +1,21 @@
+#!/sbin/openrc-run
+
+command=/usr/sbin/spreed-webrtc-server
+pidfile=/var/run/spreed-webrtc/${SVCNAME}.pid
+conf=/etc/spreed-webrtc/${SVCNAME}.conf
+logfile=/var/log/spreed-webrtc/spreed-webrtc-server.log
+
+: ${exec_user:=spreed}
+: ${exec_group:=spreed}
+
+start_stop_daemon_args="--user $exec_user --group $exec_group --background --make-pidfile"
+
+depend() {
+ need net
+ after firewall
+}
+
+start_pre() {
+ checkpath --directory ${pidfile%/*} --owner ${exec_user}:${exec_group}
+ command_args="-c $conf -l $logfile"
+}