Hosts

Craig White plug-discuss@lists.plug.phoenix.az.us
27 Feb 2003 22:36:10 -0700


On Thu, 2003-02-27 at 17:20, Don Fitz wrote:
> A question from a rookie to the hard core. I am using name based 
> hosting with Apache and I want to test my sites before I run them live. 
> I have heard that adding the domain to the hosts file temporarily will 
> allow me to fool my server into thinking that it is looking at the 
> actual domain because it checks the hosts file before dns. Is this 
> true? Is there a better way to do this?
> 
-----
It might work...I've never tried it, perhaps someone else knows the
answer to that question.

I KNOW that you can install dns (keep the firewall blocks on) and allow
only localhost to access it and set up zone files for the domains on
that machine and change /etc/resolv.conf to point to 127.0.0.1
(localhost) for dns resolution. That certainly works.

Craig