Proxy Pass | Upstream with query_string

I need to use proxy_pass directive for the upstream server which has
query_string, which allows it to authenticate to the upstream server.
How
can i ensure that query string is pass-on with every request that goes
via
this reverse proxy.

My simplified configuration is

location /RetrieveProductWS {
proxy_pass
https://apiserver/secure/v1.0/retrieveProductConditions?client_id=111-aaaa-2bbb&client_secret=aaaaabbbbbbccccddd

Please suggest possible way to achieve this requirement.

Posted at Nginx Forum:
https://forum.nginx.org/read.php?2,267095,267095#msg-267095

On Tue, May 24, 2016 at 10:17:55AM -0400, hbajaj2 wrote:

Hi there,

I need to use proxy_pass directive for the upstream server which has
query_string, which allows it to authenticate to the upstream server. How
can i ensure that query string is pass-on with every request that goes via
this reverse proxy.

proxy_pass (http://nginx.org/r/proxy_pass) allows you to build the host,
port and uri to request, using variables.

Probably you can use that to arrange what you want.

What request does the client send to nginx? What request should nginx
send to its proxy_pass upstream?

When you know that, it may be more obvious what proxy_pass configuration
to use.

Good luck with it,

f

Francis D. [email protected]

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs