On Feb 8, 4:29 am, Bradley Wright <[email protected]> wrote:
> On Feb 8, 4:39 am, Jeff <[email protected]> wrote:
>
> > I installed django today and have not been able to get it to work with
> > apache, or itself really. I have the path in the sys.path and have
> > set the settings module to point to it, but it cannot find it. It
> > works fine when I use 'python manage.py shell' or 'python manage.py
> > validate' but when I export the environment settings, the 'django-
> > admin.py validate' throws an error saying its not in the sys.path or
> > isn't valid.
>
> Could you please post:
> - The directory your Django project is in;
Django Project Directory:
'/var/www/django/legend/'
> - The directory Django itself is in; and
Django Directory:
'/usr/lib/python2.3/site-packages/django/__init__.pyc'
> - The output from the following command:
> python -c "import sys; print sys.path"
sys.path output:
['', '/usr/lib/python2.3/site-packages/MySQL_python-1.2.2-py2.3-linux-
i686.egg', '/usr/lib/python2.3/site-packages/ClientCookie-1.3.0-
py2.3.egg', '/usr/lib/python2.3/site-packages/decorator-2.2.0-
py2.3.egg', '/usr/lib/python2.3/site-packages/simplejson-1.7.1-py2.3-
linux-i686.egg', '/usr/lib/python2.3/site-packages/setuptools-0.6c9-
py2.3.egg', '/usr/lib/python2.3/site-packages/Trac-0.11.2.1-
py2.3.egg', '/var/www/django/legend', '/usr/lib/python23.zip', '/usr/
lib/python2.3', '/usr/lib/python2.3/plat-linux2', '/usr/lib/python2.3/
lib-tk', '/usr/lib/python2.3/lib-dynload', '/usr/lib/python2.3/site-
packages']
>
> ?
>
> And if you're really using mod_python already with Apache, also post
> your vhost file.
vhost file:
#Block conf
files###############################################################
<Files httpd.conf>
Order allow,deny
Deny from all
</Files>
#Django
mod_python###########################################################
<Location "/legend/">
SetHandler python-program
PythonHandler django.core.handlers.modpython
SetEnv DJANGO_SETTINGS_MODULE legend.settings
PythonOption django.root /legend
PythonDebug On
PythonPath "['/var/www/django/legend'] + sys.path"
</Location>
>
> To be honest though, if you're using Django for development you'd
> really be better off with the built-in runserver for the moment.
I am testing Django on my production server so that when development
is finished, I know I can actually use what I have done. There is no
point in doing the development if I am unable to use the work.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---