I want to point to the same servlet application for all the requests coming to "mydomain.com" and any subdomain within "mydomain.com". For e.g.: if I try to access "test.mydomain.com" or "bob.mydomain.com" it should use the same application.
The problem is tomcat does not like wild cards in "Alias" tag in the "Host" section. I tried different alternatives but still the result is the same.
We are using JBoss 4.0.5 GA version which uses Tomcat 5.5.20 internally.
I can do this may be by using an Apache in the front by using URL rewrite. But I want to avoid that and be able to configure the JBoss server to directly accept such requests.
I havent actually tried this. But, the Tomcat docs do mention that regular expressions are supported. They further mention that:
The syntax for regular expressions is different than that for 'standard' wildcard matching. Tomcat uses the java.util.regex package. Please consult the Java documentation for details of the expressions supported.
What is the regular expression that you tried? Maybe the regular expression that you mentioned was incorrect.
At this point, we are trying to figure out whether we can use wildcard support with the server configuration in Tomcat. Moving this post to our Tomcat forum, might get you better answers. If at a later point, this turns into a JBoss specific question, the moderators are free to move this back here.