On Fri, Mar 19, 2010 at 9:24 AM, W. Andrew Loe III <andrew@andrewloe.com> wrote:
> I have a Rails app that receives a POST and I would like to
> X-Accel-Redirect a file back to the client, but the fileserver is
> receiving a POST. Can I rewrite the HTTP method internally? I cannot
> find the documentation on this.
How about this?
location /proxy {
set_unescape_uri $body $arg_body;
echo_subrequest_async POST /fileserver -b $body
}
Then X-Accel-Redirect to /proxy?body=xxxx where xxxx is the content
body that you have read from within your PHP script.
Good luck :)
-agentzh
_______________________________________________
nginx mailing list
nginx@nginx.org
http://nginx.org/mailman/listinfo/nginx