import os import os path import sys path os path dirname os path realp

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
import os
import os.path
import sys
path = os.path.dirname(os.path.realpath(__file__))
if not path in sys.path:
sys.path.insert(0, path)
os.environ['DJANGO_SETTINGS_MODULE'] = 'settings'
from django.core.handlers.wsgi import WSGIHandler
application = WSGIHandler()