I'm trying to use bungle/lua-resty-reqargs from https://github.com/bungle/lua-resty-reqargs and running into something strange. When I use
local get, post, files = require "resty.reqargs"()
I get an error
2017/01/06 10:44:28 [error] 2609#0: *1 lua entry thread aborted: runtime error: ...penresty-1.11.2.2/luajit/share/lua/5.1/resty/reqargs.lua:80: attempt to index local 'options' (a nil value)
stack traceback:
coroutine 0:
...penresty-1.11.2.2/luajit/share/lua/5.1/resty/reqargs.lua: in function <...penresty-1.11.2.2/luajit/share/lua/5.1/resty/reqargs.lua:79>
content_by_lua(nginx_head.conf:165):3: in function <content_by_lua(nginx_head.conf:165):1>,
I didn't see this particular problem mentioned anywhere- maybe it's a configuration problem?
Thanks
Erik
###########################
location /test2 {
content_by_lua_block {
local get, post, files = require "resty.reqargs"()
if not get then
error(post)
end
ngx.say('hello')
}
}
Called with curl
curl -v -X POST -F "filename=@start_head.sh" http://localhost:8080/test2
----------------------------------------------------------------------
This message, and any attachments, is for the intended recipient(s) only, may contain information that is privileged, confidential and/or proprietary and subject to important terms and conditions available at http://www.bankofamerica.com/emaildisclaimer. If you are not the intended recipient, please delete this message.