0

The Mod WSGI configuration

 WSGIDaemonProcess bangtestwsgi.max140.com python-path=/home/bangwsgi/alpha:/home/bangwsgi/virtualenv/lib/python2.7/site-packages

WSGIProcessGroup bangtestwsgi.max140.com

Alias /media/ /home/bangwsgi/alpha/media/

<Directory /home/bangwsgi/alpha/media>
Order deny,allow
Allow from all
</Directory>

WSGIScriptAlias / /home/bangwsgi/alpha/alpha/wsgi.py

<Directory /home/bangwsgi/alpha/alpha>
<Files wsgi.py>
Order deny,allow
Allow from all
</Files>
</Directory>

The error:

OSError: [Errno 13] Permission denied: '/home/bangwsgi/alpha/media/img/FLOW.png'

The user "bangwsgi" owns all the directories related with the project i.e. inside /home/bangwsgi/

What could be going wrong? What other permissions can I give? What can I try?

I would be grateful for any kind of breakthrough on this. Thank you.

1 Answer 1

1

I feel silly writing the answer myself

I had to change the first line in the configuration to include -

WSGIDaemonProcess bangtestwsgi.max140.com user=bangwsgi python-path=/home/bangwsgi/alpha:/home/bangwsgi/virtualenv/lib/python2.7/site-packages

Apache was running it as root and not as the user who owned the project directories. Duh.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.