title: Redirect nginx to another domain with authorization header
body: <p>I need to redirect request from nginx to another domain, below is a working solution for redirect request but it doesn't redirect <code>Authorization</code> header from original request, is it possible to redirect to another domain with all request headers from original request?</p>
  
  <pre><code>location /test {
      return 301 https://test.com$request_uri;
  }
  </code></pre>