Documentation

Trace:

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
vaadin:mod_proxy [2020/06/04 18:21]
admin created
vaadin:mod_proxy [2023/04/17 06:21] (current)
admin
Line 1: Line 1:
 ~~NOTRANS~~ ~~NOTRANS~~
 ~~Title: Deployment: mod_proxy~~ ~~Title: Deployment: mod_proxy~~
-Usually, a JVx application will be installed on a Java application server like Tomcat, Wildfly, etc. This will be good enough for small and simple scenarios but Enterprise installations are behind a load balanced web server like Apache ​httpd, nginx, etc.+Usually, a JVx application will be installed on a Java application server like Tomcat, Wildfly, etc. This will be good enough for small and simple scenarios but Enterprise installations are behind a load balanced web server like Apache ​http server, nginx, etc.
  
-We'll show you a simple configuration option for Apache ​httpd with mod_proxy:+We'll show you a simple configuration option for Apache ​http server ​with mod_proxy:
  
-Assume the application is avaiable ​under http://​localhost:​8080/​webapp/​web/​ui/​+Assume the application is available ​under http://​localhost:​8080/​webapp/​web/​ui/​
  
-In order to use an Apache ​httpd in front of Apache Tomcat, simple add following to the config file of Apache ​httpd:+In order to use an Apache ​http server ​in front of Apache Tomcat, simple add following to the config file of Apache ​http server:
  
 <file bash> <file bash>
Line 41: Line 41:
 ProxyPassReverse / http://​localhost:​8080/​webapp/​web/​ui timeout=300 ProxyPassReverse / http://​localhost:​8080/​webapp/​web/​ui timeout=300
 </​file>​ </​file>​
 +
 +If above configuration is too complex or websockets don't work, just use this:
 +
 +<file html>
 +<​Location /dri17/>
 +  ProxyPass http://​localhost:​8080/​driprotocol/​
 +  ProxyPassReverse /​driprotocol
 +  ProxyPassReverseCookiePath ​ "/​driprotocol/" ​ "/​dri17/"​
 +
 +  RewriteEngine on
 +  RewriteCond %{HTTP:​UPGRADE} ^WebSocket$ [NC]
 +  RewriteCond %{HTTP:​CONNECTION} Upgrade$ [NC]
 +  RewriteRule (.*)/​driprotocol/​(.*) ws://​localhost:​8080/​driprotocol/​$2 [P]
 +</​Location>​
 +</​file>​
 +This configuration will map the external address ''​https://​www.mydom.ain/​dri17/''​ to the internal host: ''​http://​localhost:​8080/​driprotocol/''​
This website uses cookies for visitor traffic analysis. By using the website, you agree with storing the cookies on your computer.More information