Hi,
I am trying to log POST data through this configuration in nginx.conf.
server {
log_format myformat $request_body;
....
....
location /myresponse {
return 200;
}
location =/mypage {
if ($request_method != POST) {
return 405;
}
proxy_pass http://127.0.0.1:$server_port/myresponse;
access_log logs/myformat.log myformat;
}
}
I have googled a lot and tried almost all directives (right from resolve, internal, to checking firewall, setting request headers etc.) but nothing worked. I have nginx version 0.7.65. This same config works with the latest version of nginx.
Is there any hack to make the same work with nginx 0.7.65 also?
I can see the logged data but I get back a return code 405.
Thanks,
~ Vyom
Edited 1 time(s). Last edit at 03/13/2012 04:49PM by vyom.