httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Francis Lee Mondia <fbmon...@gmail.com>
Subject Re: [users@httpd] Help with Apache Virtual Host Config for Ubuntu Server 4 IPs
Date Tue, 25 Jun 2013 23:48:42 GMT
Hi Yehuda,

Yes, this is the Ubuntu default configuration. I did as you suggested and
it worked. Thanks for all the help.

Francis




On Tue, Jun 25, 2013 at 11:48 PM, Yehuda Katz <yehuda@ymkatz.net> wrote:

> On Tue, Jun 25, 2013 at 11:35 AM, Francis Lee Mondia <fbmondia@gmail.com>wrote:
>
>> I'm trying to configure an Ubuntu server with 4 Public IPs to display
>> "This is a shared IP site" if any of the IPs are accessed directly. The
>> server has IP-based virtual-hosts configured on the different IPs. So far,
>> I'm not having any success with it.
>>
>
> Are you using the default Ubuntu configuration where each vhost is in its
> own file?
> If so, Ubuntu should load them in alphabetical order, so which ever vhost
> is loaded first for each IP will be the default one.
> Common practice is to rename the symlinks in /etc/apache/sites-enabled to
> something like ###-NAME (where ### is the order you want the vhosts loaded
> 000,001,002, etc). That will force (at least the Ubuntu-distributed version
> of) apache to load the vhosts in that order.
>
> As long as your "This is a shared IP site" vhost is the first one loaded,
> it will be shown as the default site.
> You might need to explicitly bind the vhost to every IP address. Something
> like "*:80" won't do it.
>
> I have a setup like this and it works really well.
>
> - Y
>

Mime
View raw message