[error] 1#1: init_by_lua error: init_by_lua(conf.d/app.conf:8):2: module 'lib.resty.cors' not found:
no field package.preload['lib.resty.cors']
no file './lib/resty/cors.lua'
no file '/usr/local/share/luajit-2.1/lib/resty/cors.lua'
no file '/usr/local/share/lua/5.1/lib/resty/cors.lua'
no file '/usr/local/share/lua/5.1/lib/resty/cors/init.lua'
no file './lib/resty/cors.so'
no file '/usr/local/lib/lua/5.1/lib/resty/cors.so'
no file '/usr/local/lib/lua/5.1/loadall.so'
no file './lib.so'
no file '/usr/local/lib/lua/5.1/lib.so'
no file '/usr/local/lib/lua/5.1/loadall.so'
stack traceback:
[C]: in function 'require'
init_by_lua(conf.d/app.conf:8):2: in main chunk
[error] init_by_lua error: init_by_lua(conf.d/app.conf:8):2: module 'lib.resty.cors' not found:
no field package.preload['lib.resty.cors']
no file './lib/resty/cors.lua'
no file '/usr/local/share/luajit-2.1/lib/resty/cors.lua'
no file '/usr/local/share/lua/5.1/lib/resty/cors.lua'
no file '/usr/local/share/lua/5.1/lib/resty/cors/init.lua'
no file './lib/resty/cors.so'
no file '/usr/local/lib/lua/5.1/lib/resty/cors.so'
no file '/usr/local/lib/lua/5.1/loadall.so'
no file './lib.so'
no file '/usr/local/lib/lua/5.1/lib.so'
no file '/usr/local/lib/lua/5.1/loadall.so'
stack traceback:
[C]: in function 'require'
init_by_lua(conf.d/app.conf:8):2: in main chunk
Hi @erickskrauch, thank you for raising the issue.
The cors library (https://github.com/detailyang/lua-resty-cors) is not currently available, it requires some work to bundle it into the project.
Ends with: