Using map and proxy_pass

Markus Jelsma markus.jelsma at openindex.io
Mon May 2 16:56:19 MSD 2011


Anyone else having some thoughs on how to use the map in conjunction with 
proxy_pass to set different hosts based on the first URI segment?

On Saturday 30 April 2011 12:52:42 Markus Jelsma wrote:
> Too many. I need to generate the mappings in an external program. I'd
> rather not generate as many different locations.
> 
> 
> Thanks
> 
> > How many uri / backend mappings do you have?  You could perform the
> > above in two straight forward location blocks, based on the uri.
> > 
> > location /abc {
> > 
> > proxy_pass http://host01:8080;
> > }
> > 
> > ....
> > 
> > Posted at Nginx Forum:
> > http://forum.nginx.org/read.php?2,194480,194616#msg-194616
> > 
> > 
> > _______________________________________________
> > nginx mailing list
> > nginx at nginx.org
> > http://nginx.org/mailman/listinfo/nginx
> 
> _______________________________________________
> nginx mailing list
> nginx at nginx.org
> http://nginx.org/mailman/listinfo/nginx

-- 
Markus Jelsma - CTO - Openindex
http://www.linkedin.com/in/markus17
050-8536620 / 06-50258350



More information about the nginx mailing list