httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "John Garrett" <j...@wyoco.com>
Subject RE: [users@httpd] Serve web pages from a different server
Date Thu, 17 Jul 2014 01:57:00 GMT
Wei-min Lee & Win Lewis

 

Thanks for responding. I just got back in the house from a bike ride and after a bit I will
try using ‘mod_proxy on the vhost stanza for the site on iis be proxied by apache.’

 

I have only the one public ip address, it’s NAT from there on in.

 

Again, your help is much appreciated.

 

From: Wei-min Lee [mailto:weimin.b.lee@gmail.com] 
Sent: Wednesday, July 16, 2014 6:49 PM
To: Apache httpd users mailing list
Subject: Re: [users@httpd] Serve web pages from a different server

 

Redirect assumes the destination is directly accessible whereas with proxy/reverse proxy,
the target, as you said, Wim, could be non public servers.

~Sent from my HTC PN07120~

On Jul 16, 2014 5:42 PM, "Wim Lewis" <wiml@omnigroup.com> wrote:


On 16 Jul 2014, at 5:17 PM, John Garrett wrote:
> Is there a way to use the virtual server directive to serve web pages from a
> different server with a different IP address than my production
> FreeBSD/Apache box?
>
> I have DNS set up so website1.com and website2.com both resolve to the
> machine running Apache
>
> I've been trying to set up a virtual host in the httpd.conf of my FreeBSD
> server so when a user hits website1.com it is served off the Apache machine,
> but when the user types in the URL of website2.com Apache seamlessly
> redirects to a machine on the same subnet running IIS.

Is there a reason that the DNS record for website2.com can't simply resolve to the IP address
of the IIS machine? That seems like the simplest solution. :) Assuming that won't work for
some reason, I can think of two approaches:


1) Give a name to the IIS server (iis.website2.com, maybe) and have Apache issue a redirect
to that hostname using the Redirect directive, or mod_rewrite, or whatever. The client will
then connect to iis.website2.com to retrieve the page. Their URL bar will change to show "iis.website2.com".

2) Tell Apache to proxy the IIS server, using the ProxyPass directive. When a user connects
to website2.com, Apache will then make a connection to the IIS machine, and copy the response
back to the user. The user never directly communicates with the IIS machine (it could be behind
a firewall, for example).



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message