is it possible to set up an Apache server on a machine which is part of a LAN, then allow machines on the LAN to access the server via a custom ServerName (instead of Localhost). I want to serve a simple website in an office space using a short ServerName (no ports etc if possible), but I want to make sure this is possible (after originally being certain it was!). THanks in advance.
1 Answer
Yes, this is relatively straightforward.
Most SOHO network routers will allow you to set up a static DHCP record that ensures the IP address of the Apache server will stay the same, or will be quite happy if you assign the server an IP manually, as long as it is outside the DHCP range you're using.
Then you need to assign the name you've given the server to that IP address in DNS. Linksys/ Cisco Business Series routers and some others also allow you to set up local DNS entries that are checked first, before passing the query to the network, or you can set up dnsmasq on the same box as he Apache server to provide a local DNS server.
If you tell us what router model you have, and what operating systems you use, members of the community will be able to offer you more specific advice.
-
Hi Terence, thanks for the reply. I don't know the router model at the moment, but to give you more info, the LAN will be set up in a controlled space, with the Apache webserver being run on XP. There will be a WiFi network in the space - we want people to be able to use their phones etc to access a local web page via the WiFi network. They will all be using the same IP to connect to the page. This is only for one night, I looked at the Apache Allow directive, but didn't realise there was as much involved as you suggested, so any help greatly appreciated– samwattMay 11, 2010 at 16:40