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
https://forums.phpfreaks.com/topic/122290-creating-a-server-on-the-local-network/
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.

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.