Hi,
Sorry if it was already asked but I'd like to know if the only way to
prevent Nginx from decoding uri while using proxy_pass is:
https://stackoverflow.com/a/37584656/3515745
Here is my (simplified) conf:
server {
server_name domain1.com;
location / {
proxy_pass http://127.0.0.1:81;
}
location /api {
proxy_pass http://127.0.0.1:82/;
}
}
Location "/" is perfectly working. My problem is that "/api" location will
decode special character.
To illustrate my problem:
http://domain1.com/image1.png
=> HTTP 200
http://domain1.com/*api*/resource1.png
=> HTTP 200
http://domain1.com/image1+2.png
=> HTTP 200
http://domain1.com/*api*/resource1+2.png
=> HTTP 404
http://domain1.com/image1 2.png
=> HTTP 200
http://domain1.com/*api*/resource1 2.png
=> HTTP 404
I would like to know how to make my "/api" location respond like "/"
without decoding %?
This solution https://stackoverflow.com/a/37584656/3515745 seems to be
just a workaround.
Thanks for any hints !
Max
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Sorry if it was already asked but I'd like to know if the only way to
prevent Nginx from decoding uri while using proxy_pass is:
https://stackoverflow.com/a/37584656/3515745
Here is my (simplified) conf:
server {
server_name domain1.com;
location / {
proxy_pass http://127.0.0.1:81;
}
location /api {
proxy_pass http://127.0.0.1:82/;
}
}
Location "/" is perfectly working. My problem is that "/api" location will
decode special character.
To illustrate my problem:
http://domain1.com/image1.png
=> HTTP 200
http://domain1.com/*api*/resource1.png
=> HTTP 200
http://domain1.com/image1+2.png
=> HTTP 200
http://domain1.com/*api*/resource1+2.png
=> HTTP 404
http://domain1.com/image1 2.png
=> HTTP 200
http://domain1.com/*api*/resource1 2.png
=> HTTP 404
I would like to know how to make my "/api" location respond like "/"
without decoding %?
This solution https://stackoverflow.com/a/37584656/3515745 seems to be
just a workaround.
Thanks for any hints !
Max
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx