On 16 June 2010 06:50, Aljosa Mohorovic <[email protected]> wrote: > i'm trying to create mod_wsgi configuration that support public site/ > wsgi application and development releases. > idea is that for every release i create a clean python environment > (using virtualenv) under /var/www/wsgi/www.example.com/releases/ > --- > $ ls /var/www/wsgi/www.example.com/releases/ > r1 r2 r3 r4 r5 > --- > and using pip install new release (and dependencies) into new > virtualenv/python environment. > > if apache vhost configuration contains: > --- > ServerName www.example.com > ServerAlias r*.www.example.com > > WSGIScriptAlias / /var/www/wsgi/www.example.com/project.wsgi > --- > i can easily add: >>> site.addsitedir("/var/www/wsgi/www.example.com/current/env/lib/python2.6/site-packages/") > where /var/www/wsgi/www.example.com/current/ is symlink to latest > release (example: /var/www/wsgi/www.example.com/releases/r5/). > > so www.example.com will display latest release but i also would like > to access other releases via r(\d).www.example.com. > i can get SERVER_NAME in project.wsgi from environ but i think > sys.path will get mixed if i try to resolve this in project.wsgi or am > i wrong? > > i'm open to any suggestion, i would only like to preserve separate > virtualenv/python environments for each release. > other than that i have no problems in having project.wsgi for each > release and in apache vhost configuration point to different wsgi > files for each subdomain. > > any ideas, tips, comments are appreciated.
Does each revision have its own set of static files which also need to be mapped explicitly by Apache in order to be served up? Graham -- You received this message because you are subscribed to the Google Groups "modwsgi" 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/modwsgi?hl=en.
