Last active
December 10, 2015 12:05
-
-
Save guillaumepiot/25debe5bd6e67b311a2c to your computer and use it in GitHub Desktop.
WSGI - Upstart file for Django 1.9
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
description "uWSGI server for <domain-name>" | |
start on runlevel 2 | |
stop on runlevel [016] | |
respawn | |
exec /<path-to-myvenv>/bin/uwsgi --chdir=<code_dir> \ | |
--module=<app-name>.wsgi:application \ | |
--env DJANGO_SETTINGS_MODULE=<app-name>.settings.production \ | |
--master --pidfile=/tmp/<mysitename>-master.pid \ | |
--socket=127.0.0.1:<wsgi_port> \ | |
--processes=3 \ | |
--uid=<username> \ | |
--gid=<group_name> \ | |
--harakiri=60 \ | |
--max-requests=500 \ | |
--vacuum \ | |
--home=/var/www/<mysitename>/venv \ | |
--logto /var/www/<mysitename>/logs/wsgi.log |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment