I am not sure if I correctly formulated the subject of this post. I need to configure my Tomcat so that it listens to IP addresses and for specific IP address opens specific web application. For example. if users types aaa.aaa.aaa.aaa( dummy IP address ) tomcat opens web application "a". And if user requests http://bbb.bbb.bbb.bbb Tomcat opens web application bbb. Please help me to find how to do this. any URL or related forum message would be helpful!
looking for a solution I posted the same message in few other forums. And I cannot believe that nobody knows how to solve it. Some say that I need to create an additional virtual host.But I cannot see how does it solve the problem? are not virtual hosts local to my machine? I have tried thought and could not create even one! jakarta-tomcat-5.0.16 does not even start up if I add one. I think I am doing it correctly because I used to do it in earlier versions. or did it change? I could not find a good tutorial on how to configure Virtual hosts in jakarta-tomcat-5.0.16. Anybody can help me? Thank you!
As I recall, virtual hosts depend on the host name the request is directed to, not the IP address the request is coming from. If all you want to do is switch "web applications" based on the IP address, seems to me you could do that by an initial Filter that looks at the IP address and then decides what to do with the request. However I have never tried this. It is an interesting problem - you may have to get into the guts of Tomcat to solve it. Bill