>You may need to change the R to a P:This sends all http traffic to the private ip server
>RewriteEngine On
>RewriteCond %{HTTP_HOST} !^update.domain.com$ [NC]
>RewriteRule ^/$ http://private.ip.address/ [P,L]
I am not sure what the "technical" name is of what i am trying to do. The lines between rewrite and proxy are blurred to say the least. That is why i have tried to give an accurate description of what i am trying to do.
>This turns the rule into a proxy to that private IP, assuming that is
>what you are trying to accomplish.
Because the first suggestion did not work, i tried this one and it sends all http traffic to the iis server too.
>Finally, if you want URLS other than the root to be proxied, you may
>need to capture the URI like so:
>RewriteEngine On
>RewriteCond %{HTTP_HOST} !^update.domain.com$ [NC]
>RewriteRule ^/(.*)$ http://private.ip.address/$1 [P,L]
Just to maybe giv a better account of what i am trying to do. We have a webserver (say webserv A) that fulfills http port 80 requests and uses apache. We have another webserver that runs a program that requires it to run on 80 and uses iis. We have 1 public ip, with public dns entries for a number of hostnames and matching private dns entries. The firewall sends all port 80 traffic to the apache server. We need only updates.domain.com (this will come to the apache server) to be redirected/proxied to the iis server. We need the other websites, domain.com and the other domain.com/folder sites to still be served on the apache server. Here is the first part of the vhost file:
<VirtualHost *:80>
ServerAdmin email@xxxxxxxxxx
ServerName domain.net
ServerAlias www.domain.net
#SSLProxyEngine On
#ProxyPass /ifolder/ https://192.168.123.4/ifolder/
#ProxyPassReverse /ifolder/ https://192.168.123.4/ifolder/
RewriteEngine On
RewriteRule ^/ifolder(.*) https://%{HTTP_HOST}/ifolder/ [L]
RewriteRule ^/admin(.*) https://%{HTTP_HOST}/admin/ [L]
RewriteCond %{HTTP_HOST} !^updates.domain.net$ [NC]
RewriteRule ^/(.*)$ http://192.168.123.2/$1 [P,L]
I hoped this clears up some stuff up and makes it clear what i need apache to do.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx
Check %{HTTP_HOST} with a rewritecond or put it in a context (non
default name-based vhost) that only matches the desired hostname.