FS-4931 --resolve ok, the binary also tries to make the dir but its probably failing from dropped perms. probably if the freeswitch user had write perms in /var/run it would also work

This commit is contained in:
Anthony Minessale 2012-12-13 10:09:25 -06:00
parent 3730504693
commit ab886cad30
1 changed files with 8 additions and 1 deletions

View File

@ -18,7 +18,9 @@ NAME=freeswitch
DAEMON=/usr/bin/freeswitch
DAEMON_ARGS="-u freeswitch -g freeswitch -rp -nc -nonat"
USER=freeswitch
PIDFILE=/var/run/$NAME/$NAME.pid
GROUP=freeswitch
RUNDIR=/var/run/$NAME
PIDFILE=$RUNDIR/$NAME.pid
SCRIPTNAME=/etc/init.d/$NAME
WORKDIR=/var/lib/$NAME
@ -28,6 +30,11 @@ WORKDIR=/var/lib/$NAME
. /lib/lsb/init-functions
do_start() {
# Directory in /var/run may disappear on reboot (e.g. when tmpfs used for /var/run).
mkdir -p $RUNDIR
chown -R $USER:$GROUP $RUNDIR
chmod -R ug=rwX,o= $RUNDIR
start-stop-daemon --start --quiet \
--pidfile $PIDFILE --exec $DAEMON --name $NAME --user $USER \
--test > /dev/null \