Apache Port forwarding 80 to 8080 and accessing applications hosted both in Apache (80), i.e phpMyadmin and Tomcat (8080)
Use mod_proxy. Load module...
Second define in your virtual host:
ProxyPass /myapp http://example.com:8080/myapp
ProxyPassReverse /myapp http://example.com:8080/myapp
But this will work when your tomcat apps has only relative links.
How to publish a tomcat webapp while running on port 8080?
You should keep Tomcat
running on 8080
and use a reverse proxy on port 80
to route only what you want to the "inner" Tomcat
instance.
Easy configuration for domain:8080 to 80 Tomcat
Yes, you can use Apache Mod_Proxy for this. You use Apache2 as a front-end to your Tomcat instance.
Here is a configuration example:
<VirtualHost *:80>
ServerAdmin webmaster@localhost
ServerName site.domain.com
Redirect / /tomcat-context/
ProxyPass /tomcat-context/ http://127.0.0.1:tomcat-port/tomcat-context/
ProxyPassReverse /tomcat-context/ http://site.domain.com/tomcat-context/
ProxyPreserveHost On
</VirtualHost>
You can find more infos here.
It may seem a bit hard to grasp at first if you're not an Apache2 expert (I am not), but once you've configured your first frontend, adding more and more tomcat instances behind it is a breeze.
Or if you're lazy, change the connector port from 8080 to 80 in the conf/server.xml file in your tomcat home directory.
Easy configuration for domain:8080 to 80 Tomcat
Yes, you can use Apache Mod_Proxy for this. You use Apache2 as a front-end to your Tomcat instance.
Here is a configuration example:
<VirtualHost *:80>
ServerAdmin webmaster@localhost
ServerName site.domain.com
Redirect / /tomcat-context/
ProxyPass /tomcat-context/ http://127.0.0.1:tomcat-port/tomcat-context/
ProxyPassReverse /tomcat-context/ http://site.domain.com/tomcat-context/
ProxyPreserveHost On
</VirtualHost>
You can find more infos here.
It may seem a bit hard to grasp at first if you're not an Apache2 expert (I am not), but once you've configured your first frontend, adding more and more tomcat instances behind it is a breeze.
Or if you're lazy, change the connector port from 8080 to 80 in the conf/server.xml file in your tomcat home directory.
Related Topics
Mpc/Mpd on Linux: How to Play Local Wav File
Svn Setup of Existing Directory
How to Get Pyinstaller to Working on Ubuntu
Sending Snmp2 Trap Message from Linux Command Lne
Linux Support 802.1Ag and Y1731
Error: You Must Install at Least One Postgresql-Client-<Version> Package
Compile Errors Using Bfd.H on Linux
Building Gcc with Glibc in a Non-Standard Location Without Root
How to Install a Recent Version of Gdal on Amazon Linux
Expect Utility Is Not Working When Executing from Jenkins
How to Remove File with Special Characters
Linux Awk Comparing Two CSV Files and Creating a New File with a Flag
Set Cron Job for 1St Working Day of Every Month in Shell Scripting
Dreaming of Making My Own Os- What Should I Use? (Suggestions)
Catch Signal in Bash But Don't Finish Currently Running Command
How to Find List of Valid Locales in My Linux Using Perl
Vagrant, Shared Folder: Take Advantage of Inotify Over Nfs
List Files That Are in Directory1 But Not in Directory2 and Vice Versa