proxy_pass not passing to dynamic $host
francis at daoine.org
Sat Nov 2 16:22:42 UTC 2013
On Sat, Nov 02, 2013 at 10:21:14AM -0400, nehay2j wrote:
I suspect you'll get better help from someone else.
I'm unable to work out what it is that you want nginx to do.
> I added rewrite command so that the url doesn't show IP passed to the nginx.
What does that mean, in the problem-report format of "I use this
configuration; I make request A; I get response B; but I expect response C"?
> Curl gives a 302 because it doesnt have the sessionid with it. If there is a
> session id that is passed to the application running on
> http://22.214.171.124:8080/test, it will take us to app.
What does "take us to app" mean? The problem report should be in the
same format as above.
What happens when you add the sessionid to the curl request?
(The whole point of using curl is to make it easier to see what is
happening. If it doesn't make it easier, don't use curl. Instead, find
some other way of clearly describing the unwanted behaviour that you see.)
> If I remove the rewrite command and provides the html page in proxy_pass
> i.e. proxy_pass http://$ec2instance:8080/test/test.html, it gets to the
> test.html page of the application but does not load any .css .js files and
> says open failed "/opt/nginx/html/test/test.html.
The same problem report format will probably help here too.
Each css or js request is a separate http request, so for each one you
can say "I make request A; I get response B; but I expect response C".
Good luck with it,
Francis Daly francis at daoine.org
More information about the nginx