Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

In my server, I installed the apache and tomcat. But, when I access the my site, www.mysite.com, will for the apache. I want that access the tomcat, because I will put my site in tomcat. How to ?

share|improve this question

2 Answers 2

Set up a connector from Apache to Tomcat (one such connector is mod_jk). Here are some docs on how to do it:

http://tomcat.apache.org/connectors-doc/generic_howto/quick.html

http://tomcat.apache.org/connectors-doc/generic_howto/proxy.html

There's also this ServerFault question from a while ago:

How do I properly run Tomcat alongside Apache?

(Actually, look at the Related topics columns on the right of this page; you'll see a bunch of things related to Apache and Tomcat)

Basically, Apache is in front of Tomcat, and will act as a reverse proxy. Apache can be used to handle the static content of your site, and Tomcat the dynamic part.

share|improve this answer

You can do it enabling the ProxyPass directive in apache config file.

ProxyPass / http://127.0.0.1:8080/
ProxyPassReverse / http://127.0.0.1:8080/
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.