title: Correct proxy path in nginx.conf
body: <p>we have two servers, A and B. Server A is accessed worldwide. He has nginx installed. That's what I have in conf:</p>
  
  <pre><code>location /test {
    proxy_pass http://localserver.com;
  }
  </code></pre>
  
  <p>What it should do, is translate the addreess <a href="http://globalserver.com/test" rel="noreferrer">http://globalserver.com/test</a> (that is server A) to internal server address <a href="http://localserver.com" rel="noreferrer">http://localserver.com</a>. However, it does append the location path, that is, itries to look for <a href="http://localserver.com/test" rel="noreferrer">http://localserver.com/test</a>, which is not available at all. How can I make the proxy pass to the correct address, throwing out the last part in the location?</p>