Modified project module dirs in settings.py and setpythonpath.sh.
-export PYTHONPATH=`pwd`/lib:`pwd`/apps:$PYTHONPATH
\ No newline at end of file
+export PYTHONPATH=`pwd`/lib:`pwd`/apps:`pwd`/wolnelektury:$PYTHONPATH
\ No newline at end of file
--- /dev/null
+import sys
+import os
+from os import path
+
+# Add project directories to PYTHONPATH
+PROJECT_DIR = path.abspath(path.dirname(__file__))
+PROJECT_MODULE_DIRS = [PROJECT_DIR + '/lib', PROJECT_DIR + '/apps', PROJECT_DIR + '/wolnelektury']
+
+sys.path = PROJECT_MODULE_DIRS + sys.path
+
+
+# Run Django
+from django.core.handlers.wsgi import WSGIHandler
+
+os.environ['DJANGO_SETTINGS_MODULE'] = 'settings'
+application = WSGIHandler()
if DEBUG:
MIDDLEWARE_CLASSES.append('middleware.ProfileMiddleware')
if DEBUG:
MIDDLEWARE_CLASSES.append('middleware.ProfileMiddleware')
-ROOT_URLCONF = 'wolnelektury.urls'
TEMPLATE_DIRS = (
PROJECT_DIR + '/templates/'
TEMPLATE_DIRS = (
PROJECT_DIR + '/templates/'