I'm still completely mystified. The traceback directs me to:
"Edit your MIDDLEWARE_CLASSES setting to insert
'django.contrib.auth.middleware.AuthenticationMiddleware'
before the RemoteUserMiddleware class." But looking further
up in the traceback, it sees that d.c.a.m.AuthenticationMiddleware
*is* there, and it's true -- I already have it in my
MIDDLEWARE_CLASSES setting before the RemoteUserMiddleware class,
so how could mod_wsgi possibly not be finding it?
See below for more details on my configuration ...
Steve
On 12/30/2010 06:17 PM, Stephen Waterbury wrote:
> I am baffled, and it's probably something simple I'm missing ...
> I just need to send a message for help and then I'll see it ...
> (maybe ... ;)
>
> My set up:
> * apache2 on Ubuntu 10.04
> * mod_wsgi 3.3, compiled with python 2.6.5 (the system python)
> (but Ubuntu's mod_wsgi package was apparently not the problem)
> * django installed in a virtualenv with python 2.6.5 also
> * 2 django apps, one running on ':80' virtual host and one on
> ':8000' virtual host, each with a separate wsgi script (of course)
> * apache server config (apache.conf) has WSGIPythonHome directive:
> 'WSGIPythonHome [path to virtualenv directory]'
> * virtualenv directory has python interpreter in its bin dir and
> python packages installed in its lib dir, including all django
> libs
> * I have verified that AuthenticationMiddleware can be imported
> successfully from the command line within the virtualenv using
> the virtualenv's python intepreter
> * both django apps live within the virtualenv directory,
> each in its own "project" directory there
> * both apps are configured in apache with WSGIDaemonProcess directive
>
> The error I continue to get is:
>
> "ImproperlyConfigured at /
>
> "The Django remote user auth middleware requires the
> authentication middleware to be installed. Edit your
> MIDDLEWARE_CLASSES setting to insert
> 'django.contrib.auth.middleware.AuthenticationMiddleware' before
> the RemoteUserMiddleware class."
>
> The relevant sections of the settings.py files for the apps are:
> --------------
> MIDDLEWARE_CLASSES = (
> 'django.middleware.common.CommonMiddleware',
> 'django.contrib.sessions.middleware.SessionMiddleware',
> 'django.contrib.auth.middleware.AuthenticationMiddleware',
> 'django.contrib.auth.middleware.RemoteUserMiddleware',
> )
>
> AUTHENTICATION_BACKENDS = (
> 'django.contrib.auth.backends.RemoteUserBackend',
> )
> ---------------
>
> Ultimately I'll be using Active Directory (Kerberos) auth, but for
> purposes of testing the REMOTE_USER stuff I've configured Basic
> Authentication, and it is working (I authenticate successfully
> before seeing that error message).
>
> Any suggestions welcome! (I can send the whole error page if it
> would help, but I'll need to launder it a little.)
>
> TIA!
> Steve
>
--
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+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
No comments:
Post a Comment