[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Having Apache webserver always redirect to Tomcat App Server

Posted on 2008-11-04
3
Medium Priority
?
895 Views
Last Modified: 2013-12-02
Experts & all,

I have an Apache Webserver that currently uses mod_jk to commnunicate to the Tomcat Appserver and that works flawlessly.

What I am trying to figure out is how NOT to show the Tomcat webpage but always have the webserver redirect or rewrite so that the default is ALWAYS my application running on the Appserver.

Right now if my users enter the public IP address (for example 123.45.67.111) and only the IP address, the Tomcat default webpage shows up. How can I have the public IP address always point to 123.45.67.111/MyApp, where MyApp is my applications that runs in the appserver.

Thanks,
- Eric

0
Comment
Question by:eric_dd
  • 2
3 Comments
 
LVL 10

Accepted Solution

by:
kukno earned 500 total points
ID: 22877248
Hi,

change the index.html page of your apache document. It should contain a HTML redirect to your application URL.

Basically you need this in the html file:

<META HTTP-EQUIV="Refresh" CONTENT="1; URL=MyApp">

See here: http://billstclair.com/html-redirect2.html

Regards
Kurt
0
 

Author Comment

by:eric_dd
ID: 22877383
Hi Kurt,

That works great :), so here are your points. I am not to sure if the following will be considered another question, but, I dont want to loose the tomcat page, so i renamed it to tomcat.html. How can I only allow loading this page from the 8080, i.e. prevent port 80 and 443 from seeing this (or all ports except 8080)
0
 
LVL 10

Expert Comment

by:kukno
ID: 22878237
>How can I only allow loading this page from the 8080, i.e. prevent port 80 and 443 from seeing this (or all ports except 8080)

it really depends how you configured apache and tomcat to co-operate. There are some pretty good tutorials out there:

http://tomcat.jajakarta.org/tomcat/tomcat3.2-4.0/tomcat-3.2.3/doc/tomcat-apache-howto.html
0

Featured Post

Visualize your virtual and backup environments

Create well-organized and polished visualizations of your virtual and backup environments when planning VMware vSphere, Microsoft Hyper-V or Veeam deployments. It helps you to gain better visibility and valuable business insights.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If your site has a few sections that need to be secure when data is transmitted between the server and local computer, such as a /order/ section for ordering or /customer/ which contains customer data, etc it would of course be recommended to secure…
If you are a web developer, you would be aware of the <iframe> tag in HTML. The <iframe> stands for inline frame and is used to embed another document within the current HTML document. The embedded document could be even another website.
Loops Section Overview
Is your OST file inaccessible, Need to transfer OST file from one computer to another? Want to convert OST file to PST? If the answer to any of the above question is yes, then look no further. With the help of Stellar OST to PST Converter, you can e…
Suggested Courses
Course of the Month18 days, 22 hours left to enroll

834 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question