<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content=text/html;charset=gb2312 http-equiv=Content-Type>
<META name=GENERATOR content="MSHTML 8.00.7600.16535"></HEAD>
<BODY style="PADDING-LEFT: 10px; PADDING-RIGHT: 10px; PADDING-TOP: 15px" 
id=MailContainerBody leftMargin=0 topMargin=0 CanvasTabStop="true" 
name="Compose message area">
<DIV><FONT face=Calibri>Anyone please?</FONT></DIV>
<DIV><FONT face=Calibri></FONT>&nbsp;</DIV>
<DIV style="FONT: 10pt Tahoma">
<DIV><BR></DIV>
<DIV style="BACKGROUND: #f5f5f5">
<DIV style="font-color: black"><B>From:</B> <A title=bing_ran@hotmail.com 
href="mailto:bing_ran@hotmail.com">Ƚ±ø</A> </DIV>
<DIV><B>Sent:</B> Monday, May 10, 2010 5:37 PM</DIV>
<DIV><B>To:</B> <A title=nginx@nginx.org 
href="mailto:nginx@nginx.org">nginx@nginx.org</A> </DIV>
<DIV><B>Subject:</B> proxy to a .Net webservice</DIV></DIV></DIV>
<DIV><BR></DIV>
<DIV><FONT face=Calibri>Hi,</FONT></DIV>
<DIV><FONT face=Calibri></FONT>&nbsp;</DIV>
<DIV><FONT face=Calibri>Company is testing nginx with a .net SOAP web service. 
The nginx and web service runs on two different ports. The problem is the web 
service returns the response with links that point to the web service's own TCP 
port instead of the port of the Nginx, i.e., the web service server does not 
realize that requests come via a proxy on a different port. </FONT></DIV>
<DIV><FONT face=Calibri></FONT>&nbsp;</DIV>
<DIV><FONT face=Calibri>Here is the config being used:</FONT></DIV>
<DIV><FONT face=Calibri></FONT>&nbsp;</DIV>
<DIV><FONT face=Calibri>// ....</FONT></DIV>
<DIV><FONT face=Calibri></FONT>&nbsp;</DIV>
<DIV>server<BR>{<BR>&nbsp;&nbsp;&nbsp;&nbsp;listen&nbsp; 
89;<BR>&nbsp;&nbsp;&nbsp;&nbsp;server_name&nbsp; mysolr;<BR></DIV>
<DIV>&nbsp;&nbsp;&nbsp;&nbsp;location / 
{<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;proxy_pass&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<A 
href="http://mysolr/">http://mysolr/</A>;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;proxy_redirect 
off;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;proxy_set_header Host 
$host:$server_port;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;proxy_set_header 
X-Real-IP&nbsp; 
$remote_addr;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;proxy_set_header 
REMOTE-HOST 
$remote_addr;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;proxy_set_header 
X-Forwarded-For 
$remote_addr;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;proxy_set_header 
X-Forwarded-For&nbsp;$proxy_add_x_forwarded_for;<BR>&nbsp;&nbsp;&nbsp;&nbsp;}</DIV>
<DIV>}</DIV>
<DIV><FONT face=Calibri></FONT>&nbsp;</DIV>
<DIV><FONT face=Calibri>In the above case, response comes back with all embedded 
links on port 80 rather than on 89. </FONT></DIV>
<DIV><FONT face=Calibri></FONT>&nbsp;</DIV>
<DIV><FONT face=Calibri>Any help is appreciated~</FONT></DIV>
<DIV><FONT face=Calibri></FONT>&nbsp;</DIV>
<DIV><FONT face=Calibri>Bing</FONT></DIV>
<DIV><FONT face=Calibri></FONT>&nbsp;</DIV>
<P>
<HR>

<P></P>_______________________________________________<BR>nginx mailing 
list<BR>nginx@nginx.org<BR>http://nginx.org/mailman/listinfo/nginx<BR></BODY></HTML>