felippe
(felippe delMexico)
August 24, 2011, 3:54pm
1
Hi, there
I need your help this thig is killing me …
I’ve deployed my app on tomcat and want to redirect all the traffic www.example.com to www.example.com:8080/myapp
I installed apache2 with mod_proxy but running into the following issues:
If I access myapp at www.example.com:8080/myapp it’s working fine
but when I setup proxyPass on apache
ProxyRequests On
ProxyPass / http://www.example.com/myapp/
ProxyPassReverse / http://www.example.com/myapp/
and try to access www.example.com I got a vaading error while trying to access widgetset under /myapp/vaadin/…/cache.js
any idea?
Thanks!
aschild
(André Schild)
August 25, 2011, 5:26am
2
Are you using the latest vaadin version ?
I think in some versions of this spring vaadin did not correctly detect it’s server name/port…
felippe
(felippe delMexico)
August 25, 2011, 6:07am
3
André
thanks for dropping by.
I guess we are running on vaadin 6.6.5
anyone managed to get apache and tomcat working with mod_proxy using vaadin 6.6.5 ?
Thanks
aschild
(André Schild)
August 25, 2011, 7:20am
4
We use apache and mod_jk since the beginning with vaadin and see no problems at all…
In your mod_proxy config I don’t see a reference to port 8080 of the servlet engine… ?
André
Teemu
(Teemu Pöntelin)
August 25, 2011, 7:26am
5
Hi,
my guess is that you need to add also proxy configuration for accessing the
VAADIN
directory (containing themes and widgetsets). And you should add it before the root
ProxyPass
rule.
Something like this might work:
ProxyRequests On
ProxyPass /myapp/VAADIN http://www.example.com:8080/myapp/VAADIN
ProxyPassReverse /myapp/VAADIN http://www.example.com:8080/myapp/VAADIN
ProxyPass / http://www.example.com:8080/myapp/
ProxyPassReverse / http://www.example.com:8080/myapp/
felippe
(felippe delMexico)
August 26, 2011, 1:31am
6
Teemu,
Thanks a lot! It works. You made my day
just need to add / after VAADIN though
posting here the final code if anyone needs it later
ProxyRequests On
ProxyPass /myapp/VAADIN/ http://www.example.com:8080/myapp/VAADIN/
ProxyPassReverse /myapp/VAADIN/ http://www.example.com:8080/myapp/VAADIN/
ProxyPass / http://www.example.com:8080/myapp/
ProxyPassReverse / http://www.example.com:8080/myapp/
Steffen9
(Steffen Ewert)
February 23, 2013, 2:53pm
7
HI all,
I know this thread is old, but a comment from me for all whose reading this thread:
Be aware of using the option “ProxyRequests On”. If your server is available on internet this is may be not what you want. With “ProxyRequests On” you will have a “Open proxy” server. See at
http://httpd.apache.org/docs/2.2/mod/mod_proxy.html
http://wiki.apache.org/httpd/ProxyAbuse
https://en.wikipedia.org/wiki/Open_proxy
Regards,
Steffen
iBoss
(iBoss obama)
August 13, 2013, 4:04pm
8
I success with following setting in httpd.conf. vaadin application running on 192.168.0.88:8080 ROOT
#ProxyRequests On
ProxyPass /VAADIN/ http://192.168.0.88:8080/VAADIN/
ProxyPassReverse /VAADIN/ http://192.168.0.88:8080/VAADIN/
ProxyPass /UIDL http://192.168.0.88:8080/UIDL
ProxyPassReverse /UIDL http://192.168.0.88:8080/UIDL
ProxyPass /crm http://192.168.0.88:8080/
ProxyPassReverse /crm http://192.168.0.88:8080/