Rewriting location directive by upstream servers
thunder hill
thunderhill4 at gmail.com
Thu Sep 25 19:50:18 UTC 2014
Hi,
I have two back end application servers behind nginx. The configuration is
as follows
upstream backend1 {
server 10.1.1.11;
}
upstream backend2 {
server 10.2.2.2;
}
server {
listen 80;
server_name mysite.com;
location /appl1 {
# proxy_set_header X-Real-IP $remote_addr;
proxy_pass https://backend1/;
}
location /app2 {
proxy_pass https://backend2/;
}
}
When I access mysite.com/app1 the upstream server rewrites the url like
mysite.com/login instead of mysite.com/app1/login and the result is a
blank page.
Users are allowed either mysite.com/app1 or mysite.com/app2. In both the
cases app1 and app2 are getting rewritten with login or some other
extension. How to solve this issue.?
Regards
T
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.nginx.org/pipermail/nginx/attachments/20140926/7930ea4d/attachment.html>
More information about the nginx
mailing list