hello, im new member LQ.
i have a problem with apache proxy.
my scenario is,
- i have webserver in intranet intranet.com and i have example.com webserver to forward all webserver intranet.com .
- my configuration apache is work. all user in internet can access intranet.com via example.com.
- all links on webpage example.com is ready be writen with example.com for example, if int intranet.com have link intranet.com/login.php its already be writen with example.com/login.php
- problem appears when client try to login that web, after user enter username and password the client web browser always attempt to link intranet.com NOT example.com.
here my apache proxy configuration for that web.
Code:
NameVirtualHost *:80
<VirtualHost *:80>
ServerAdmin admin@example.com
RewriteEngine On
RewriteCond %{HTTP_HOST} !^example\.com [NC]
RewriteCond %{HTTP_HOST} !^$
RewriteRule ^/(.*) intranet.com/$1 [L,R]
ProxyRequests Off
ProxyHTMLEnable On
ProxyPass /forum http://intranet.com/
ProxyPassReverse /forum http://intranet.com/
SetOutputFilter INFLATE;proxy-html;DEFLATE
ProxyHTMLURLMap http://intranet.com/ /forum/
ErrorLog "/var/log/apache/rileks-error.log"
CustomLog "/var/log/apache/rileks-access.log" common
</VirtualHost>
please your advice
.
sorry for my bad english.