Re: name based hosting [message #25022 is a reply to message #25019] |
Thu, 13 December 2007 07:03   |
Thomasd
Messages: 39 Registered: December 2007
|
Member |
|
|
how does this work when it comes to the nat part then?
let's assume I have two VPS (10.0.0.1 and 10.0.0.2) and each has apache listening to port 80, do I need to fw traffic from port 80 (on the main node) to both VPS and each decides if they want to handle it?
assuming my main ip is x.x.x.x,
iptables -t nat -A PREROUTING -p TCP -d x.x.x.x --dport 80 -j DNAT --to-destination 10.0.0.1
iptables -t nat -A PREROUTING -p TCP -d x.x.x.x --dport 80 -j DNAT --to-destination 10.0.0.2
is that correct?
From what I understand with the virtual host section, you have one apache server listening and then it dispatches the calls toweard the virtual hosts, but in this case we have several unrelated apache hosts, so how does this work?
[Updated on: Thu, 13 December 2007 07:06] Report message to a moderator
|
|
|