Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Question about setting up web server

 
David Cheong
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dear all,

I would like to ask if it is possible to have one dns domain serving two web servers? for example, my domain is www.abc.com and there are two tomcat web servers each has a web application. When internet users browse www.abc.com, it will show web page from tomcat 1 and when users browse ww.abc.com/app1, it will be showing web pages from tomcat 2.
Is it possible to config that? if yes, it is config in the tomcat aspect or network aspect?

Thanks.
 
Amit Ghorpade
Bartender
Posts: 2854
10
Fedora Firefox Browser Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Not sure if you are trying to do load balancing in Tomcat.
 
Ulf Dittmer
Rancher
Posts: 42967
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think this should be achievable if you front the Tomcats with an Apache httpd running the mod_rewrite module (which is a commonly used module that may even be part of the standard Apache installation these days). (Assuming the approach Amit points to doesn't work out.)
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic