I have one Windows machine on my LAN, the rest is Linux. It all sits
behind a Linksys NAT box (attached to a cable connection).
I use DynDNS, and host a personal web site at
www.mygreatsite.org (this
name is fictional). This is free DNS, with one IP address (the one that my
cable modem obtains via DHCP), and one name, with "Wildcard" recognition
enabled (DynDNS will pass any machine prefix on my base domain name to the
same IP address as the base domain).
I also have IIS running on the Windows box. It has some services that are
not readily available on Linux, so it comes in handy from time to time.
Right now, the IIS server is configured on port 8080. On the NAT
firewall, port 80 is opened up to my main Apache installation on my Linux
server, and port 8080 is opened up to IIS on the Windows box.
Right now, from the outside world, a request to
www.mygreatsite.org gets
directed to the Apache/Linux server, and a request to
www.mygreatsite.org:8080 gets directed to the Windows setup.
Port 8080 is a bit of a pain because some firewalls (like
the one where I work) block it. In fact, my office network blocks
just about everything except port 80 and a VERY SMALL set of other
ports. What I'd like to be able to do is create a virtual host called
windows.mygreatsite.org, which would be accessible via port 80, but on the
back end would really be serviced by IIS (with the actual port used by IIS
transparent to the user).
I've tried doing this using VirtualHost directives - setting up both the
default Linux VirtualHost and a second VirtualHost pointing to the
Windows machine, but it doesn't work. I get "Connection Refused" (and I
did make sure everything was open on the Windows side, such as IIS
configuration and Windows XP's own firewall).
Does anyone know the proper method for doing this, or a reference that
explains it - i.e., having Apache answer over one IP connection for two
different names, and then supply the corresponding content from two
different machines. Seems to me this must be possible. What do I have to
change in httpd.conf, /etc/hosts, DynDNS, etc. in order to get this to
work?