Problem with paths
Hi everyone,
I have a strange problem. On my home server, everything works.
I have a Ubuntu server with all things installed what i needed.
Now i want to emigrate all things to a live configuration
situation:
path of project:
/home/django/profile/settings.py
because i use Plesk on OpenSuse i needed to make a fastcgi file.
Mod_python doesnt work on some way.
so i have created a file like mysite.fcgi:
#!/usr/bin/python
import sys, os
# Add a custom Python path.
sys.path.insert(0, "/home/django")
sys.path.append('/home/django/profile')
#Calculate the path based on the location of the WSGI script.
apache_configuration= os.path.dirname(__file__)
project = os.path.dirname(apache_configuration)
workspace = os.path.dirname(project)
sys.path.append(workspace)
# Switch to the directory of your project. (Optional.)
os.chdir("/srv/www/vhosts/test.com/httpdocs")
# Set the DJANGO_SETTINGS_MODULE environment variable.
os.environ['DJANGO_SETTINGS_MODULE'] = "profile.settings"
from django.core.servers.fastcgi import runfastcgi
runfastcgi(method="threaded", daemonize="false")
Now i have make all files redirecting to the mysite.fcgi.
But it doesnt work.
If i go to test.com i get the follow message:
---
Page not found (404)
Request Method: GET
Request URL: http://www.test.com/srv/www/
vhosts/test.com/httpdocs/
---
The rewrite :
---
<Location "/">
Options MultiViews FollowSymLinks +Includes +ExecCGI
AllowOverride All
AddHandler fastcgi-script .fcgi
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{PATH_INFO} !-f
RewriteBase /
RewriteRule ^(.*)$ mysite.fcgi/$1 [QSA,L]
</Location>
---
I have changed my domain trough test.com because it isn't relevant
Can someone find the solution?
Thanks
--
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.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home