tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tbye ...@viperpit.com>
Subject Preserve wildcard domains for access from request.getServerName()
Date Tue, 25 Feb 2003 20:19:17 GMT
I currently use Tomcat 4.1.18 with Apache. I have all wildcard domains 
mapped to my Controller servlet. When a request is made to the servlet and 
I call request.getServerName(), the sub-domain is being truncated from the 
Full Qualified Domain Name. Anyone know of a solution/configuration that 
will allow my servlet to see the original FQDN that made the request.
For example. If a user hits bob.domain.com. I want request.getServerName() 
to return "bob.domain.com"... right now it returns "domain.com".

Yes, the server name in Apache is "domain.com". There is a serveralias to
*.domain.com.

Yes, server.xml is configured as <Host name="domain.com"... />

I am familiar with the <Alias></Alias> tags however having tested 
<Alias>*.domain.com</Alias> I know that it will not work.

Is there a way to preserve these wildcard subdomains such that
getServerName() will show them?

Any help is appreciated.

Thanks,
Tyler


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message