I've read the following and am still stuck and wondering what piece of this puzzle I am missing. If anyone has any ideas, please do comment!
http://docs.djangoproject.com/en/1.3/howto/deployment/modwsgi/ http://code.google.com/p/modwsgi/wiki/IntegrationWithDjango Using the Django 1.3 development webserver, everything works fine. Migrating to Apache 2.x with WSGI 3.3, not so much. The WSGI part of the picture seems to function as intended, but not with my Django stuff. Visiting / gives me the *expected* 404 (see urls.py below) Visiting /admin (which is really the entirety of my needs) gives me: "Site matching query does not exist." ------- BEGIN Apache config ---------- <VirtualHost *:80> ServerName rcf-hostdb.our.org # A single dir with nothing else but our WSGI wrapper, for security <Directory "/rcfwebapps/apps/hostdb/hostdb_project/apache"> Order allow,deny Allow from all </Directory> # Handle all requests via the WSGI wrapper, django.wsgi WSGIScriptAlias / /rcfwebapps/apps/hostdb/hostdb_project/apache/django.wsgi # And one other directory for storing static files, like CSS, favicon.ico <Directory /rcfwebapps/apps/hostdb/hostdb_project/static> Order deny,allow Allow from all </Directory> # Now redefine where to find those static files (not via WSGI) Alias /robots.txt /rcfwebapps/apps/hostdb/hostdb_project/static/robots.txt Alias /favicon.ico /rcfwebapps/apps/hostdb/hostdb_project/static/favicon.ico AliasMatch ^/([^/]*\.css) /rcfwebapps/apps/hostdb/hostdb_project/static/styles/$1 Alias /media/ /rcfwebapps/apps/hostdb/hostdb_project/static/media/ </VirtualHost> ------ END Apache Config --------- ------ BEGIN url mapping --------- urlpatterns = patterns('', (r'^admin/', include(admin.site.urls)), ) ------ END url mapping --------- ------ BEGIN apache/django.wsgi -------- #!/rcfwebapps/apps/hostdb/bin/python import os import sys path = '/rcfwebapps/apps/hostdb' if path not in sys.path: sys.path.append(path) os.environ['DJANGO_SETTINGS_MODULE'] = 'hostdb_project.settings' os.environ['PYTHON_EGG_CACHE'] = '/rcfwebapps/apps/hostdb/egg-cache' import django.core.handlers.wsgi application = django.core.handlers.wsgi.WSGIHandler() ------- END django.wsgi -------- My "site" directory tree is as follows (the site is 'hostdb_project' with 1 app named 'hostdb'): |-agent-- |-apache- | | |-admin----|-hostdb- |-hostdb-|-fixtures- |-hostdb_project-| |-static--- | | |-css (symlink to django/contrib/admin/media/css) |-static-|-media----|-img (symlink to django/contrib/admin/media/img) | |-js (symlink to django/contrib/admin/media/js) |-styles--- Full exception copy/paste: Environment: Request Method: GET Request URL: http://rcf-hostdb.our.org/admin/ Django Version: 1.3 Python Version: 2.7.1 Installed Applications: ['django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.sites', 'django.contrib.messages', 'django.contrib.staticfiles', 'hostdb', 'django.contrib.admin'] Installed Middleware: ('django.middleware.common.CommonMiddleware', 'django.contrib.sessions.middleware.SessionMiddleware', 'django.middleware.csrf.CsrfViewMiddleware', 'django.contrib.auth.middleware.AuthenticationMiddleware', 'django.contrib.messages.middleware.MessageMiddleware') Traceback: File "/rcfwebapps/apps/hostdb/lib/python2.7/site-packages/django/core/handlers/base.py" in get_response 111. response = callback(request, *callback_args, **callback_kwargs) File "/rcfwebapps/apps/hostdb/lib/python2.7/site-packages/django/contrib/admin/sites.py" in wrapper 214. return self.admin_view(view, cacheable)(*args, **kwargs) File "/rcfwebapps/apps/hostdb/lib/python2.7/site-packages/django/utils/decorators.py" in _wrapped_view 93. response = view_func(request, *args, **kwargs) File "/rcfwebapps/apps/hostdb/lib/python2.7/site-packages/django/views/decorators/cache.py" in _wrapped_view_func 79. response = view_func(request, *args, **kwargs) File "/rcfwebapps/apps/hostdb/lib/python2.7/site-packages/django/contrib/admin/sites.py" in inner 196. return self.login(request) File "/rcfwebapps/apps/hostdb/lib/python2.7/site-packages/django/views/decorators/cache.py" in _wrapped_view_func 79. response = view_func(request, *args, **kwargs) File "/rcfwebapps/apps/hostdb/lib/python2.7/site-packages/django/contrib/admin/sites.py" in login 331. return login(request, **defaults) File "/rcfwebapps/apps/hostdb/lib/python2.7/site-packages/django/utils/decorators.py" in _wrapped_view 93. response = view_func(request, *args, **kwargs) File "/rcfwebapps/apps/hostdb/lib/python2.7/site-packages/django/views/decorators/cache.py" in _wrapped_view_func 79. response = view_func(request, *args, **kwargs) File "/rcfwebapps/apps/hostdb/lib/python2.7/site-packages/django/contrib/auth/views.py" in login 59. current_site = get_current_site(request) File "/rcfwebapps/apps/hostdb/lib/python2.7/site-packages/django/contrib/sites/models.py" in get_current_site 92. current_site = Site.objects.get_current() File "/rcfwebapps/apps/hostdb/lib/python2.7/site-packages/django/contrib/sites/models.py" in get_current 25. current_site = self.get(pk=sid) File "/rcfwebapps/apps/hostdb/lib/python2.7/site-packages/django/db/models/manager.py" in get 132. return self.get_query_set().get(*args, **kwargs) File "/rcfwebapps/apps/hostdb/lib/python2.7/site-packages/django/db/models/query.py" in get 349. % self.model._meta.object_name) Exception Type: DoesNotExist at /admin/ Exception Value: Site matching query does not exist. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.