substation wrote:
Sorry I missed your earlier messages otherwise i would have helped you
out!
No problem!
If you are setting up many virtual hosts you can simply create a
virtual host per site in sites-available and you can remove the
NameVirtualHost reference from all but the root server [default file].
I do this. Actually I have a single virtualhost in sites-available along
the lines of:
NameVirtualHost *
Include /path/to/site/configs/*.conf
.. with a separate file in the later directory for each vhost. (I do it
that way for several reasons not relevant here!)
80 is just a port reference and again - once you have this set-it-up
correctly in your default apache server site you can ignore it in the
virtual hosts files
I think you may have missed the point that all my Name-based
VirtualHosts share port 80 (as you'd expect) but it all broke when I
tried to get one of the virtual hosts to also respond to port 8080. In
order to specify a port for one vhost, it seems I had to specify ports
for them all (which seems odd, but that's where I ended up).
Based on that, if you have set-up BIND9 correctly it should be working
perfectly.
I'm not sure of the relevance of DNS here? Unless you tend to use:
<VirtualHost www.example.com>
rather than
<VirtualHost ip.address>
ServerName www.example.com
(I use the latter so that DNS issues do not prevent the server coming up)
BTW:
On a real world server or office server you should only use * marker
for your default server root and not your virtual hosts.
Use the default server site to create a holding page for your virtual
hosts.
Your virtual hosts should run from the IP address you give them.
On name-based virtual hosts, they're sharing IP addresses rather than
having their own. Most of the servers I administer only have a single IP
for the web server, unless additional IPs are required for https.
Otherwise, on error - you will not know if [a] your IP address block
is failing [b] your dns is failing or [c] risk various other security
loop holes.
[a] is obvious when you only have one IP and can still reach the server
at all.
[b] is a non-issue if you don't put the site names in the VirtualHost
directive (which is why I do it that way - been burnt before!)
[c] I'm not sure about
NB: In my case, * is just a shortcut for entering the same IP address
for each VirtualHost. That's not for laziness, it's to limit the impact
if subsequent IP address changes.
Two options:
1] If you use debian or ubuntu you are forced to everything manually.
It is very easy!
I do, and I'm happy at the command line anyway. None of my servers have
a GUI anyway.
Thanks for the advice though.
--
Mark Rogers // More Solutions Ltd (Peterborough Office) // 0845 45 89 555
Registered in England (0456 0902) at 13 Clarke Rd, Milton Keynes, MK1 1LG
_______________________________________________
Peterboro mailing list
[email protected]
https://mailman.lug.org.uk/mailman/listinfo/peterboro