tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jieryn <>
Subject Re: Apache Tomcat 7.x: Host+Alias and HTTP 301
Date Mon, 16 Sep 2013 13:53:56 GMT

On Sat, Jul 20, 2013 at 12:36 AM, jieryn <> wrote:
> I have multiple host names which resolve to the same
> application context, e.g. (host) and
> (alias). I have implemented this within conf/server.xml via Host and
> Alias definitions.

Just to close the loop here, I eventually did solve this with
URLRewrite filter. The documentation I was looking at was inaccurate
or maybe just mismatched against the version of the library being
used.. Alas, here is the working URLRewrite rule:

    <note>Domain name change from $OLDHOST1, with $OLDHOST2 Alias, to
    <condition type="server-name" operator="equal"
    <condition type="server-name" operator="equal">$OLDHOST2</condition>
    <to last="true" type="permanent-redirect">http://$NEWHOST/$1</to>


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message