Use rewrite /blog to transparently proxy to another app
Fernando Perez
lists at ruby-forum.com
Mon Aug 2 20:11:24 MSD 2010
Hi,
I have various applications running RoR. In order to improve code
maintenability I have decided to use a single blog application that will
be used by different apps.
So a user will be browsing app1 at: app1.com
And when he wants to check out the blog of app1 he goes to:
app1.com/blog which behind the scene transfer the request to my blog
engine.
I tried the following:
server {
...
location ^~ /blog/ {
proxy_set_header Host $http_host;
proxy_pass http://blog$uri;
}
}
But it seems to ∞ly redirect the request.
Thanks for your upload
--
Posted via http://www.ruby-forum.com/.
More information about the nginx
mailing list