ProxyPass syntax
Posted by: ChrisRChamberlain (89.241.190.---)
Date: October 05, 2008 06:14PM

Hi all

Have 2 TLDs and would like to host them on 2 different servers on a network.

1st TLD works as expected through its entry in httpd-vhosts.conf on 1st server

2nd TLD should be to a Windows box but running IIS - may not be possible?

Basic code in httpd-vhosts.conf on 1st server for second TLD tried so far is:-

<VirtualHost *:80>
ServerName www.xxx.com
ServerAlias xxx.com xxx
ProxyPass /local IP address
DocumentRoot C:/Inetpub/wwwroot
</VirtualHost>

With that code in httpd-vhosts.conf on 1st server can't then restart Apache.

Any ideas please?

TIA

Options: ReplyQuote
Re: ProxyPass syntax
Posted by: stevenmartin99 (---.b-ras1.blp.dublin.eircom.net)
Date: October 05, 2008 06:43PM

u have one router?
and 2 computers,,
and you want to host a site on each computer,,


do u have wamp installed on both?

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: ProxyPass syntax
Posted by: toivo (---.nsw.bigpond.net.au)
Date: October 05, 2008 11:17PM

Hi,

The ProxyPass directive maps remote servers to the URL space of the current Virtual Host, so that the content served by the other server becomes part of the domain of the current Virtual Host, which is not the case here.

Your Virtual Host does not want to know about the DocumentRoot folder in the server running IIS, therefore it throws a syntax error.

You can use mod_rewrite to solve your problem, see
[httpd.apache.org],
and
[httpd.apache.org],
especially the section about 'Move Homedirs to Different Webserver'.

You can test your configuration at any time by running the command 'httpd -t'. It should say 'Syntax OK'.

By the way, you have two domain names, not TLDs :-)

Regards,

toivo
Sydney, Australia

Options: ReplyQuote
Re: ProxyPass syntax
Posted by: ChrisRChamberlain (89.241.190.---)
Date: October 06, 2008 09:20AM

Steven, toivo

Thanks for your replies.

Before pursuing the mod_rewrite option, can you advise that this will enable Apache and IIS to effectively share port 80 on a LAN through the one external IP address?

Chris

Options: ReplyQuote
Re: ProxyPass syntax
Posted by: toivo (---.nsw.bigpond.net.au)
Date: October 06, 2008 10:15AM

Cheers. I support several sites with one external IP address serving a number of domains and subdomains through name-based virtual hosts. Even though I have not used two servers exactly like your configuration, I do not think IIS cares where the request comes from when it sends the response to the browser :-)


Regards,

toivo
Sydney, Australia

Options: ReplyQuote
Re: ProxyPass syntax
Posted by: ChrisRChamberlain (89.241.190.---)
Date: October 06, 2008 10:29AM

Thanks for the encouragement!

Have enabled mod_rewrite in Apache.

Any ideas on where example code and where to place it might be found?

Chris

Options: ReplyQuote
Re: ProxyPass syntax
Posted by: yfastud (Moderator)
Date: October 06, 2008 01:33PM

either in main config file httpd.conf which effect the whole webserver or in htaccess file which only effect the folder and subfolder(s) it's in; remember to restart wamp to take effect

Have fun,

FREE One A Day
FREE Photo
FREE Games
FREE Websites
FREE Portable GPS
FREE WAMP Guides



Edited 1 time(s). Last edit at 10/06/2008 03:25PM by yfastud.

Options: ReplyQuote
Re: ProxyPass syntax
Posted by: ChrisRChamberlain (89.241.190.---)
Date: October 06, 2008 02:42PM

I assume by main config file you mean httpd.conf?

Options: ReplyQuote
Re: ProxyPass syntax
Posted by: yfastud (Moderator)
Date: October 06, 2008 03:17PM


Options: ReplyQuote


Sorry, only registered users may post in this forum.