Thanks again, this thing still does not work, I tried these, still only the
example default page works, inside links get connection timed out.
Any more ideas?
Thanks
server {
listen ipaddress:80;
server_name
;
error_log c:/nginx-1.2.0/logs/error_log debug;
root C:/apache-tomcat-7.0.26_64/webapps;
location ^~ /examples/* {
proxy_pass
;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
}
location ^~ /examples/jsp$ {
proxy_pass
;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
}
On Thu, May 10, 2012 at 1:23 AM, Jamie Maher <jamie.maher(a)gmail.com> wrote:
Hi Dave,
I'm fairly new to nginx myself, but try the following in your setup:
location ^~ /examples {
proxy_pass
http://localhost:8181/examples;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
}
I think your setup before only matched the /examples/ exactly, and not
anything that's underneath that path as well. eg. the /examples/jsp/
didn't match your previous location exactly.
Hopefully that works for you.
Jamie
On 5/9/2012 9:22 PM, Geo Du wrote:
Hi, Jamie,
Thanks very much for your response, I tried nginx like that:
location /examples/ {
proxy_pass
http://localhost:8181/examples/;
#proxy_redirect
http://localhost:8082/examples/
http://mypublic.com/examples/;
proxy_set_header Host $http_host;
}
to test my examples webapp inside tomcat, the link
http://mypublic.com/examples/ works fine, but there are links inside
here
as
http://mypublic.com/examples/jsp/
http://mypublic.com/examples/jsp/jsp2/el/basic-arithmetic.html
and others, all of them do not work, I tested by turning on and off the
proxy_redirect, but no difference.
Of course I tried the xwiki deployed under tomcat in parallel with the
examples app, but xwiki does not work either, they all gave me timeout
error on the browser.
Any clue? would you please share your setup with me?
Thanks very much for your help.
Dave
On Mon, May 7, 2012 at 11:03 PM, Jamie Maher <jamie.maher(a)gmail.com>
wrote:
> Hi Dave
>
> I am using nginx and I believe I had to add an extra header to ensure
> things worked for proxy pass.
>
> Checkout the following regarding the host header:
>
>
>
http://www.simplicidade.org/notes/archives/2011/02/nginx_proxy_host_header.…
>
> There must be an equivalent setting for your setup.
>
> Jamie
> On May 6, 2012 10:13 AM, "Geo Du" <dddu88(a)gmail.com> wrote:
>
>> Hi, all,
>>
>> I got a problem with our xwiki site setup, I have apache webserver and
>> tomcat behind with xwiki 3.5 deployed, when I do login, logout or
> clicking
>> buttons on the server machine browser with
>>
http://localhost:8082/xwiki/bin/login/XWiki/XWikiLogin, I can login,
>> everything works fine, but if I use external public internet to access
> our
>> xwiki site like:
http://mydomain.com/xwiki/bin/login/XWiki/XWikiLogin,
I
>> got the login page shown up, but if I
login, it redirects me to
>> localhost/xwiki/bin/view/Main/WebHome, which points to my localhost,
not
my
server
mydomain.com machine, then from the
browser address bar, if I
change
the localhost url to this url:
http://mydomain.com/xwiki/bin/view/Main/WebHome, I can see the page
correctly.
Hers is my httpd.conf file setup:
ProxyPass /xwiki
http://localhost:8082/xwiki
ProxyPassReverse /xwiki
http://localhost:8082/xwiki
Any clue what is going on?
Thanks
Dave
_______________________________________________
devs mailing list
devs(a)xwiki.org
http://lists.xwiki.org/mailman/listinfo/devs
_______________________________________________
devs mailing list
devs(a)xwiki.org
http://lists.xwiki.org/mailman/listinfo/devs
_______________________________________________
devs mailing list
devs(a)xwiki.org
http://lists.xwiki.org/mailman/listinfo/devs
_______________________________________________
devs mailing list
devs(a)xwiki.org
http://lists.xwiki.org/mailman/listinfo/devs