Skip to content

Instantly share code, notes, and snippets.

@liveashish
Last active September 27, 2017 02:21
Show Gist options
  • Save liveashish/ba51fea40f4af7df00c04ee9f9e160e5 to your computer and use it in GitHub Desktop.
Save liveashish/ba51fea40f4af7df00c04ee9f9e160e5 to your computer and use it in GitHub Desktop.
PROJECTNAME=teamwork
APPNAME=worktogether
PROJECTDIR=/home/ubuntu/$PROJECTNAME/
LOGFILE=$PROJECTDIR'log/gunicorn.log'
ERRORFILE=$PROJECTDIR'log/gunicorn-error.log'
NUM_WORKERS=3
ADDRESS=127.0.0.1:8000
cd $PROJECTDIR
#source ~/.bashrc
#workon $APPNAME
exec gunicorn $APPNAME.wsgi:application \
-w $NUM_WORKERS --bind=$ADDRESS \
--log-level=debug \
--log-file=$LOGFILE 2>>$LOGFILE 1>>$ERRORFILE &
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment