Allow to override the --bind option to gunicorn
This commit is contained in:
parent
6c42b8ac0c
commit
dea4e97759
26
init.d
26
init.d
|
@ -20,29 +20,29 @@ PIDFILE=$RUN_DIR/$NAME.pid
|
|||
LOG_DIR=/var/log/$NAME
|
||||
SCRIPTNAME=/etc/init.d/$NAME
|
||||
MANAGE_SCRIPT=/usr/lib/$NAME/manage.py
|
||||
SOCKFILE=$RUN_DIR/$NAME.sock
|
||||
BIND=unix:$RUN_DIR/$NAME.sock
|
||||
|
||||
USER=$NAME
|
||||
GROUP=$NAME
|
||||
|
||||
DAEMON_ARGS="--pid $PIDFILE \
|
||||
--user $USER --group $GROUP \
|
||||
--daemon \
|
||||
--access-logfile $LOG_DIR/gunicorn-access.log \
|
||||
--log-file $LOG_DIR/gunicorn-error.log \
|
||||
--bind=unix:$SOCKFILE \
|
||||
--workers=10 \
|
||||
--worker-class=sync \
|
||||
--timeout=60 \
|
||||
--name $NAME \
|
||||
passerelle.wsgi:application"
|
||||
|
||||
# Exit if the package is not installed
|
||||
[ -x $DAEMON ] || exit 0
|
||||
|
||||
# Read configuration variable file if it is present
|
||||
[ -r /etc/default/$NAME ] && . /etc/default/$NAME
|
||||
|
||||
DAEMON_ARGS=${DAEMON_ARGS:-"--pid $PIDFILE \
|
||||
--user $USER --group $GROUP \
|
||||
--daemon \
|
||||
--access-logfile $LOG_DIR/gunicorn-access.log \
|
||||
--log-file $LOG_DIR/gunicorn-error.log \
|
||||
--bind=$BIND \
|
||||
--workers=10 \
|
||||
--worker-class=sync \
|
||||
--timeout=60 \
|
||||
--name $NAME \
|
||||
passerelle.wsgi:application"}
|
||||
|
||||
# Load the VERBOSE setting and other rcS variables
|
||||
. /lib/init/vars.sh
|
||||
|
||||
|
|
Loading…
Reference in New Issue