January 08, 2005

Apache module mod_proxy

ProxyPass allows remote servers to be mapped into the space of the local server

You have to enable mod_proxy during buid apache
e.g.
./configure --prefix=/usr/local/apache --sysconfdir=/usr/local/apache/conf \
--enable-module=so --enable-module=rewrite --enable-module=proxy

Example:
a FreeBSD server, WAN IP 140.117.53.147, LAN IP 192.168.0.1, with Apache 1.3.33
a Windows IIS server, LAN IP 192.168.0.6, Gateway 192.168.0.1

Example Settings 1: (all can connect iis.pank.org)

<VirtualHost 140.117.53.147>
  ServerName iis.pank.org
  ProxyPass / http://192.168.0.6/
</VirtualHost>

Example Settings 2: (restrict from, only 140.117.0.0/16 can connect)

<VirtualHost 140.117.53.147>
  ServerName iis.pank.org
   <Directory proxy:*>
   Order deny,allow
   Deny from all
   Allow from 140.117.0.0/16
  </Directory>
  ProxyPass / http://192.168.0.6/
</VirtualHost>

note: Setting ProxyRequests to off does not disable use of the ProxyPass directive.
ref.
Apache module mod_proxy
R-Proxy

Posted by pank at January 8, 2005 03:04 PM
Comments
Post a comment













Remember personal info?