Pulkit Singhal <pulkitsinghal <at> gmail.com> writes:

> 
> > Using RemoteAddrValve as <Host/> subelement won't work, as will
> >apply to both, any suggestions?
> 
> Why not just do:
> 
> <Host name="www.mydomain.com"  ...... >
>        <Context path="" docBase="" debug="0" ..... />
> </Host>
> <Host name="www-i.mydomain.com <http://www.mydomain.com/>"  ...... >
>        <Context path="" docBase="" debug="0" ..... />
> </Host>
> 

Pulkit,
that option is not possible since both domains are served by just one instance
of the application, that is one Host, that´s the motivation behind using
<Alias/> in first place.

I have managed to create a Tomcat Valve similar to RemoteAddrValve, which
instead of obtaining just remote ip addr, it also gets the server name, making
possible to use this kind of pattern in the valve allow atribute:

   <Valve class=".....myValve"
allow="www-i.mydomain.com/192.168.*.*,www.mydomain.com/10.146.*.*" />

--p





---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to