Rename PID_DIR to RUN_DIR to uniformize with other packages

This commit is contained in:
Benjamin Dauvergne 2014-09-16 11:51:29 +02:00
parent 91714d71f4
commit 9f78110e26
1 changed files with 7 additions and 6 deletions

View File

@ -15,10 +15,11 @@ PATH=/sbin:/usr/sbin:/bin:/usr/bin
DESC=portail-citoyen
NAME=portail-citoyen
DAEMON=/usr/bin/gunicorn
PID_DIR=/var/run/$NAME
RUN_DIR=/var/run/$NAME
LOG_DIR=/var/log/$NAME
PIDFILE=$PID_DIR/$NAME.pid
PIDFILE=$RUN_DIR/$NAME.pid
SCRIPTNAME=/etc/init.d/$NAME
SOCKFILE=$RUN_DIR/$NAME.sock
USER=portail-citoyen
GROUP=portail-citoyen
@ -28,7 +29,7 @@ DAEMON_ARGS="--pid $PIDFILE \
--daemon \
--access-logfile $LOG_DIR/gunicorn-access.log \
--log-file $LOG_DIR/gunicorn-error.log \
--bind=unix:$PID_DIR/$NAME.sock \
--bind=unix:$SOCKFILE
--workers=10 \
--worker-class=sync \
--timeout=60 \
@ -50,9 +51,9 @@ portail_citoyen2.wsgi:application"
# Depend on lsb-base (>= 3.0-6) to ensure that this file is present.
. /lib/lsb/init-functions
# Create pid directory
if [ ! -d $PID_DIR ]; then
install -d -m 755 -o $USER -g $GROUP $PID_DIR
# Create /run directory
if [ ! -d $RUN_DIR ]; then
install -d -m 755 -o $USER -g $GROUP $RUN_DIR
fi
#