Hello,

I've been experimenting with switching a Django app over to uWSGI, I'm 
currently nginx with apache and mod_wsgi proxied to from nginx, but 
would much prefer to cut Apache out of the stack altogether.

My initial experimentation went well, and was quite easy, but I had 
trouble when adding 2 sites to my usage.

I'm running it on a Debian server, from latest uWSGI version tar, and 
the init.d script from 
https://library.linode.com/web-servers/nginx/installation/reference/init-deb.sh,
 
then attempting to pass in the dynamic app params from my nginx config:

location / {
                 include uwsgi_params;
                 uwsgi_pass 127.0.0.1:9001;
                 uwsgi_param UWSGI_CHDIR 
/home/projectcausal/domains/gargoyle.me/checkout/wsgi;
                 uwsgi_param UWSGI_PYHOME 
/home/projectcausal/domains/gargoyle.me/checkout/wsgi;
                 uwsgi_param UWSGI_SCRIPT wsgi_alias;
         }

As I said this works fine on one site (the above is my production.conf 
for the live site), but when using the exact same config (but with 
different paths and script name) for a staging site, I get an unexpected 
result:

location / {
                 include uwsgi_params;
                 uwsgi_pass 127.0.0.1:9001;
                 uwsgi_param UWSGI_CHDIR 
/home/projectcausal/domains/gargoyle.me/checkout/wsgi;
                 uwsgi_param UWSGI_PYHOME 
/home/projectcausal/domains/gargoyle.me/checkout/wsgi;
                 uwsgi_param UWSGI_SCRIPT wsgi_alias_staging;
         }

They both work, but whichever site is accessed first after a re-start of 
uwsgi will be the one which both sites load in nginx, or rather I 
suspect shared processes are using the same code caches for the sites, 
despite being completely different paths on disk (the wsgi scripts above 
both point to completely separately buildouted checkouts).

Any ideas what I'm doing wrong?

Cheers,
--
Wes
_______________________________________________
uWSGI mailing list
[email protected]
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi

Reply via email to