[Catalyst] Too greedy name-based Virtual Host

mnichols at mojosoft.org mnichols at mojosoft.org
Thu May 17 11:43:15 GMT 2007


Xavier Robin <robin0 at etu.unige.ch> writes:

> Hello,
>
> I'm still in trouble with virtual hosts...
>
> We have a domain domain.tld with several machines. On one of them,
> apache can be called using http://site1.domain.tld. It is configured
> to listen to port 80 with Listen *:80.
>
> Now we would like to bind our Catalyst app on http://site2.domain.tld
> on this machine site1. Our DNS are correctly installed and apache is
> reachable by both addresses.
>
> Here comes the Virtual Host :
>
> <VirtualHost site2.domain.tld:80>
> 	ServerName    site2.domain.tld:80
> 	DocumentRoot  /home/xrobin/MIAPE/root
> 	LogLevel      debug
> 	ErrorLog      /home/xrobin/catalyst_error_log
> 	<Location />
> 		SetHandler           modperl
> 		PerlResponseHandler  MIAPE
> 	</Location>
> </VirtualHost>
>
> This works, and http://site2.domain.tld calls our Catalyst
> application, and it seems to work properly.
>
> But strangely enough, our application is now bound also on
> site1.domain.tld ! (so all the usual pages are not reachable anymore).

It is my understanding that you need a second vhost config for site1. Apache defaults to the first one it finds so you could name it 0_site1.conf to make sure it is the default. 

mojo



More information about the Catalyst mailing list