httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Yan Seiner <...@seiner.com>
Subject [users@httpd] mod_proxy and redirects
Date Mon, 27 Jan 2014 14:43:07 GMT
I am trying to set up a simple mod_proxy:

<VirtualHost *:80>
     ErrorLog "/var/log/apache2/wrt_error.log"
         LogLevel debug
     CustomLog "/var/log/apache2/wrt_access.log" combined

ProxyPreserveHost On
ProxyRequests Off
ServerName xxx.com
ServerAlias www.xxx.com
ProxyPass /foo/ http://localhost:8002/
ProxyPassReverse /foo/ http://localhost:8002/
</VirtualHost>

The problem I am having is that the server at localhost:8002 immediately 
issues a redirect to /cgi-bin, and I can't figure out how to handle that 
in the proxy:

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" 
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="refresh" content="0; URL=/cgi-bin/yyy" />
</head>
<body style="background-color: black">
<a style="color: white; text-decoration: none" 
href="/cgi-bin/yyy">redirected page</a>
</body>
</html>

I have several web servers at localhost:800?.  The web servers at 
localhost:800? are embedded machines so I can't easily change the code.

Any suggestions on how to proceed?

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


Mime
View raw message