Nginx and Websphere
sampy
nginx-forum at nginx.us
Thu May 28 06:35:10 UTC 2015
Hi,
Francis Daly Wrote:
-------------------------------------------------------
> On Wed, May 27, 2015 at 07:27:25AM -0400, sampy wrote:
>
> Hi there,
>
> > What does "doesn't work" mean?
> >
> > web browser don't show the web and appears the error "webint don't
> exists
> > in DNS", but query arrives to the balanced server
>
> You see "webint", but you include "proxy_set_header Host $host;" in
> your config?
>
> That is unexpected to me.
>
> Could you show the response to
>
> curl -i http://web.domain.com/
>
I just remove "proxy_set_header Host $host"
And the result for curl:
HTTP/1.1 302 Found
Server: nginx/1.8.0
Date: Thu, 28 May 2015 06:27:41 GMT
Content-Type: text/html
Content-Length: 0
Connection: keep-alive
X-Powered-By: Servlet/3.0
Location: http://webint:9080/WebApp/main.jsf
Content-Language: es-ES
Set-Cookie: JSESSIONID=0000EOXejCoK14218Xm2cCtzxdd:-1; Path=/; HttpOnly
Expires: Thu, 01 Dec 1994 16:00:00 GMT
Cache-Control: no-cache="set-cookie, set-cookie2"
> from your client machine? Perhaps there is more than one redirection
> happening.
>
> > What response did you want to get instead?
> >
> > Oviously the web
>
> What http response? A 301 redirect to a different url; or a 200 with
> some specific content?
>
> (Assume that I don't know anything about WebSphere.)
>
> > What response do you get if you do
> >
> > curl -H Host:web.domain.com -i
> http://wasint-1.domain.com:9080/WebApp
> >
> > from the nginx server?
> >
> > HTTP/1.1 302 Found
> >
> > X-Powered-By: Servlet/3.0
> > Location: http://web.domain.com:9080/WebApp/
> > Content-Language: es-ES
> > Content-Length: 0
>
> Ok - after you show the response from the new curl command above --
> the one that you make of your nginx server directly -- it might become
> clear whether that Location: header is being modified, or what it
> should
> be modified to be.
>
> http://nginx.org/r/proxy_redirect may be useful. (Or just removing the
> "proxy_set_header Host $host;".)
>
> > Does that match one of the previous two answers?
> >
> > Yes, but don't. Let me explain. It appears that the proxy_pass
> works,
> > because adds the port and /WebApp, but don't show the web that is
> served in
> > the host.
>
> One request gets one response.
>
> Take the requests one at a time, and the path to the desired end state
> may become clear.
>
> (For example: I suspect that you may want to change the proxy_pass to
> be
> just to "http://webint", and you may want an extra "location=/{return
> 301
> /WebApp/;}", but the response from the first few requests will
> probably
> show whether or not that is useful.)
>
> Cheers,
>
> f
> --
> Francis Daly francis at daoine.org
>
> _______________________________________________
> nginx mailing list
> nginx at nginx.org
> http://mailman.nginx.org/mailman/listinfo/nginx
Posted at Nginx Forum: http://forum.nginx.org/read.php?2,259127,259209#msg-259209
More information about the nginx
mailing list