Serving Django Admin Static Media Files with Apache WSGI on Ubuntu

481 views
Skip to first unread message

Ganesh Kumar

unread,
Dec 20, 2011, 2:58:56 AM12/20/11
to django...@googlegroups.com, rpravee...@gmail.com
Hi guys, I trying with Serving Django Admin Static Media Files with
Apache WSGI on Ubuntu.10.04

This my config files. example_proj.wsgi
http://dpaste.com/675674/

apache config file. 000-default

http://dpaste.com/675675/

my setting.py

http://dpaste.com/675678/

please guide me. what mistakes I have do it.

-Ganesh


Did I learn something today? If not, I wasted it.

Timothy Makobu

unread,
Dec 20, 2011, 3:39:45 AM12/20/11
to django...@googlegroups.com
The way I do it, is I use the staticfilesapp https://docs.djangoproject.com/en/dev/howto/static-files/
then i have the web server use the static folder in my project folder to serve requests for /static

works well on ep.io



--
You received this message because you are subscribed to the Google Groups "Django users" group.
To post to this group, send email to django...@googlegroups.com.
To unsubscribe from this group, send email to django-users...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.


Timothy Makobu

unread,
Dec 20, 2011, 3:45:14 AM12/20/11
to django...@googlegroups.com
Also, here is a working wsgi settings file:

***

import os
import sys

sys.path.append(os.path.dirname(__file__).replace('\\','/'))
os.environ['DJANGO_SETTINGS_MODULE'] = 'settings'

from django.core.handlers.wsgi import WSGIHandler

application = WSGIHandler()

***
Reply all
Reply to author
Forward
0 new messages