0

I am trying to run a django project on apache web server. I followed this tutorial to setup the server with my django project. I am using ubuntu 14.04 and my project is located in a virualenv on my desktop.

My /000-default.conf settings:

Alias /static /home/manish/Desktop/starchi/ekomerz/static
<Directory /home/manish/Desktop/starchi/ekomerz/static>
        Require all granted
</Directory>

<Directory /home/manish/Desktop/starchi/ekomerz/ekomerz>
        <Files wsgi.py>
                Require all granted
        </Files>
</Directory>

WSGIDaemonProcess ekomerz python-path=/home/manish/Desktop/starchi/ekomerz:/home/manish/Desktop/starchi/lib/python2.7/site-packages
WSGIProcessGroup ekomerz
WSGIScriptAlias / /home/manish/Desktop/starchi/ekomerz/ekomerz/wsgi.py

But it is giving me a 500 Internal Server Error. What am I doing wrong? I can run my project from my virtual environment.

EDIT:

Error-Log

Manish Gupta
  • 4,438
  • 18
  • 57
  • 104
  • 1
    You should check your logs to figure out what the actual error is. – Sayse Jan 25 '16 at 09:43
  • @Sayse i uploaded error log. It says `Target WSGI script cannot be loaded as Python module`. But couldn't figure out how to solve. – Manish Gupta Jan 25 '16 at 09:52
  • http://stackoverflow.com/questions/6454564/target-wsgi-script-cannot-be-loaded-as-python-module – Anonymous Jan 25 '16 at 10:27
  • I figured it out. It seems error was in my Log Handlers. The project was trying to write to root directory. So I gave absolute path in django.settings. – Manish Gupta Jan 25 '16 at 11:03

0 Answers0