Jump to content

Creating a server on the local network


drewjoh

Recommended Posts

Hi All,

 

I'm wanting to create a local Ubuntu or CentOS server on my local network with virtualhosts, so I can use URLs like "testserver1" in my browsers and it accesses the local server box. (For web dev testing)

 

I found I can do this by setting up the virtualhosts in Apache, and then on my other machines (Macs) I have to add that to the hosts file to have it use a specific IP address (local one).

 

What I'm wanting is to just be able to define new hosts in Apache, and it be accessible across the local network without modification to each computer.

 

I was able to do this easily with Windows Server 2000 about 3 years ago.  I would just setup the server with a name, and typing that in the address bar in a browser accessed that local server.  Can Apache not do something similar?  (Yes, I've Googled lots!)

Link to comment
Share on other sites

You would need to setup a local DNS server (bind). This could run on the same machine as Apache if you wished. Then all you need do is have your machines use this DNS server for domain name resolution. Each time you add a new domain to apache, add a new domain to your dns server and restart.

 

I use the exact same setup here quite effectively.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.