You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gentoo-overlay/net-voip/yate/files/yate.initd

34 lines
738 B

#!/sbin/openrc-run
# Copyright 1999-2015 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
extra_started_commands="reload"
YATE_PIDFILE=${YATE_PIDFILE:-/var/run/${SVCNAME}.pid}
YATE_BINARY=${YATE_BINARY:-/usr/bin/yate}
depend() {
need net
use mysql postgresql zaptel
}
start() {
ebegin "Starting ${SVCNAME}"
start-stop-daemon --start --exec "${YATE_BINARY}" \
-- -d -p "${YATE_PIDFILE}" ${YATE_OPTS}
eend $?
}
stop() {
ebegin "Stopping ${SVCNAME}"
start-stop-daemon --stop --pidfile="${YATE_PIDFILE}"
eend $?
}
reload() {
ebegin "Reloading ${SVCNAME}"
start-stop-daemon --signal HUP --exec "${YATE_BINARY}" \
--pidfile "${YATE_PIDFILE}"
eend $?
}