Created
January 19, 2010 00:29
-
-
Save vinilios/280533 to your computer and use it in GitHub Desktop.
django uwsgi compatible wsgi file
This file contains hidden or 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
# name it something like mysitedotcom_wsgi | |
# /usr/bin/uwsgi -s 127.0.0.1:46235 -t 10 -M -p 1 -C -w mysitedotcom_wsgi -H ~/venvs/virtualenv | |
import sys, os | |
import django.core.handlers.wsgi | |
# lets redirect print statements to stderr | |
# (this is useful to redirect print statements to web servers error log file) | |
sys.stdout = sys.stderr | |
# PATH DEBUG | |
# print "\n".join(sys.path) | |
# force settings | |
# os.environ['DJANGO_SETTINGS_MODULE'] = 'settings' | |
application = django.core.handlers.wsgi.WSGIHandler() | |
applications = {'/': application, } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment