Make IP Address point to webroot instead of virtual hosts' documentroot

Posted by Reuben L. on Super User See other posts from Super User or by Reuben L.
Published on 2012-06-11T07:42:13Z Indexed on 2012/06/13 4:43 UTC
Read the original article Hit count: 259

Filed under:
|
|
|
|

I used to have a one-to-one domain name and IP. Recently I've paid for a second domain name and decided to host it on the same box and IP. As such, I added virtualhosts to point each domain name to a different document root (i.e. /var/www/webbie1 and /var/www/webbie2).

The question I have is, can I still make the IP, e.g. http://XXX.XXX.XXX.XXX, point to the webroot, i.e. /var/www/? If so, how do I go about doing it?

For a fuller picture, the box is on an Ubuntu server OS and I'm using apache2 as the app server. the changes I made to enable to virtual hosts were in the apache2.conf file with the <VirtualHost [IP address]> ... </VirtualHost> tags.

Thanks.

© Super User or respective owner

Related posts about ubuntu

Related posts about server