aports/main/icecast/icecast.initd
Leonardo Arena ec8d0960d3 main/icecast: modernize init.d
Remove conf.d and make init compatible with supervise-daemon
2020-12-17 18:14:09 +00:00

19 lines
396 B
Bash

#!/sbin/openrc-run
name="Icecast 2"
command="/usr/bin/icecast"
command_background=yes
: ${cfgfile:=/etc/icecast.xml}
: ${command_user:=icecast}
: ${command_group:=icecast}
command_args="-c $cfgfile ${ICEC_OPTS}"
pidfile="/run/icecast/icecast.pid"
depend() {
need net
after firewall
}
start_pre() {
checkpath --directory --owner $command_user:$command_group ${pidfile%/*} /var/log/icecast
}