Have you considered a reverse proxy to something like gunicorn? The way that I know how to do this involves mod_rewrite - I don't know of of the top of my head whether it also requires mod_proxy. Are these available to you. I understand that gunicorn is to be preferred to fastcgi, which I haven't used. I haven't actually set up gunicorn, but have done reverse proxy configuration for it (a skill acquired while suffering under plone).
Another approach is your own separate Apache build, assuming you have development tools and either the ability to run this in place of the provided apache or the ability to proxy, as above, but this time to your private Apache. Still, if its true that the best these guys can provide is python2.4 and mod_python, maybe it is time to switch. I'm pretty happy with my linode. For shared hosting I've deployed a lot of sites to webfaction, and have no complaints. EC2, if I recall, is a bit dear, but you can roll your own distro for it, if necessary. There's a big wonderful world out there. Bill On Thu, Mar 21, 2013 at 10:38 AM, Tim Walzer <modusoperandip...@gmail.com>wrote: > Thats what I was afraid of. Unfortunately Media Temple DVs come > pre-installed with Plesk which in turn comes pre-installed with weird > versions of different software packages, none of which are mod_wsgi. At > this point I have not figured out a way to install mod_wsgi without > breaking the entire thing. Maybe its time to move on to a different host. > > On Thursday, March 14, 2013 3:37:22 PM UTC-6, Tim Walzer wrote: >> >> I am currently trying to install Django on a Mediatemple DV (4.0) server >> and have the installation be within a virtualenv. The django app will be >> run from a subdomain, *parts.domain.com*, while the root domain * >> domain.com* is serving a wordpress site. >> >> I have django installed inside the virtualenv at */var/www/vhosts/ >> domain.com/parts/env/* The virtual environment is *'env'. *The server >> is running python 2.4.3, but I needed at least 2.6, so I installed 2.6 >> inside the virtual env and that worked perfectly for setting up the initial >> django site. Now the problem comes with the running of django. >> >> I created a vhost.conf file under */var/www/vhosts/parts.domain.com/conf* >> * >> * >> <Location "/"> >> SetHandler python-program >> PythonPath >> "['/var/www/vhosts/domain.com/**parts/env/bin<http://domain.com/parts/env/bin>', >> '/var/www/vhosts/domain.com/**parts/env/store<http://domain.com/parts/env/store>'] >> + sys.path" >> PythonHandler virtualproject >> SetEnv DJANGO_SETTINGS_MODULE store.settings >> </Location> >> >> The path to virtualproject, referenced in the PythonHandler line, is * >> /var/www/vhosts/domain.com/parts/env/bin/virtualproject.py. * >> >> The contents of that file are: >> >> *activate_this = '/var/www/vhosts/domain.com/ >> parts/env/bin/activate_this.py'* >> *execfile(activate_this, dict(__file__=activate_this))* >> * >> * >> *from django.core.handlers.modpython import handler* >> * >> * >> The activate_this.py file is the one that comes with the virtualenv >> installation >> >> When I go to the site *parts.domain.com*, I get the following error in >> the apache logs: >> >> [Thu Mar 14 17:29:45 2013] [error] [client ] PythonHandler >> virtualproject: Traceback (most recent call last): >> [Thu Mar 14 17:29:45 2013] [error] [client ] PythonHandler >> virtualproject: File "/usr/lib64/python2.4/site-** >> packages/mod_python/apache.py"**, line 287, in HandlerDispatch\n >> log=debug) >> [Thu Mar 14 17:29:45 2013] [error] [client ] PythonHandler >> virtualproject: File "/usr/lib64/python2.4/site-** >> packages/mod_python/apache.py"**, line 464, in import_module\n module >> = imp.load_module(mname, f, p, d) >> [Thu Mar 14 17:29:45 2013] [error] [client ] PythonHandler >> virtualproject: File "/var/www/vhosts/domain.com/** >> parts/env/bin/virtualproject.**py<http://domain.com/parts/env/bin/virtualproject.py>", >> line 4, in ?\n from django.core.handlers.modpython import handler >> [Thu Mar 14 17:29:45 2013] [error] [client ] PythonHandler >> virtualproject: ImportError: No module named django.core.handlers.modpython >> >> I can only think that this is happening because apache is attempting to >> use the system default python2.4 instead of the one in my virtualenv where >> django is installed. How do I fix this? >> > -- > You received this message because you are subscribed to the Google Groups > "Django users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to django-users+unsubscr...@googlegroups.com. > To post to this group, send email to django-users@googlegroups.com. > Visit this group at http://groups.google.com/group/django-users?hl=en. > For more options, visit https://groups.google.com/groups/opt_out. > > > -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com. To post to this group, send email to django-users@googlegroups.com. Visit this group at http://groups.google.com/group/django-users?hl=en. For more options, visit https://groups.google.com/groups/opt_out.