For a while now I have been getting this warning whenever I start nginx when it is build with the LUA option: [tykling@mail ~]$ sudo service nginx start Performing sanity check on nginx configuration: nginx: the configuration file /usr/local/etc/nginx/nginx.conf syntax is ok nginx: configuration file /usr/local/etc/nginx/nginx.conf test is successful Starting nginx. nginx: [alert] detected a LuaJIT version which is not OpenResty's; many optimizations will be disabled and performance will be compromised (see https://github.com/openresty/luajit2 for OpenResty's LuaJIT or, even better, consider using the OpenResty releases from https://openresty.org/en/download.html) [tykling@mail ~]$ The maintainer is aware of this warning, I reported it back in February by email. Recently (since ports r508962 I think) I am still getting the warning but nginx now refuses to start: [tykling@staging3 ~]$ sudo service nginx start Performing sanity check on nginx configuration: nginx: the configuration file /usr/local/etc/nginx/nginx.conf syntax is ok nginx: configuration file /usr/local/etc/nginx/nginx.conf test is successful Starting nginx. nginx: [alert] detected a LuaJIT version which is not OpenResty's; many optimizations will be disabled and performance will be compromised (see https://github.com/openresty/luajit2 for OpenResty's LuaJIT or, even better, consider using the OpenResty releases from https://openresty.org/en/download.html) nginx: [error] lua_load_resty_core failed to load the resty.core module from https://github.com/openresty/lua-resty-core; ensure you are using an OpenResty release from https://openresty.org/en/download.html (rc: 2, reason: module 'resty.core' not found: no field package.preload['resty.core'] no file './resty/core.lua' no file '/usr/local/share/luajit-2.0.5/resty/core.lua' no file '/usr/local/share/lua/5.1/resty/core.lua' no file '/usr/local/share/lua/5.1/resty/core/init.lua' no file './resty/core.so' no file '/usr/local/lib/lua/5.1/resty/core.so' no file '/usr/local/lib/lua/5.1/loadall.so' no file './resty.so' no file '/usr/local/lib/lua/5.1/resty.so' no file '/usr/local/lib/lua/5.1/loadall.so') [tykling@staging3 ~]$ This is preventing me from upgrading nginx to solve the recent vulnerabilities https://vuxml.freebsd.org/freebsd/87679fcb-be60-11e9-9051-4c72b94353b5.html
A commit references this bug: Author: joneum Date: Thu Sep 12 08:49:53 UTC 2019 New revision: 511862 URL: https://svnweb.freebsd.org/changeset/ports/511862 Log: The lua module for nginx is intended to be used with Openrestys luajit branch. PR: 240438 240274 Sponsored by: Netzkommune GmbH Changes: head/www/nginx/Makefile.extmod
Hello, Thank you. My poudriere has built the new nginx package but it didn't seem to do anything, I still get the same error: [tsr@webproxy3 ~]$ pkg info | grep nginx nginx-1.16.1_2,2 Robust and small WWW server [tsr@webproxy3 ~]$ pkg info | grep lua luajit-openresty-2.1.20190626 Just-In-Time Compiler for Lua (OpenResty branch) [tsr@webproxy3 ~]$ sudo service nginx restart Performing sanity check on nginx configuration: nginx: the configuration file /usr/local/etc/nginx/nginx.conf syntax is ok nginx: configuration file /usr/local/etc/nginx/nginx.conf test is successful Stopping nginx. Waiting for PIDS: 66697. Performing sanity check on nginx configuration: nginx: the configuration file /usr/local/etc/nginx/nginx.conf syntax is ok nginx: configuration file /usr/local/etc/nginx/nginx.conf test is successful Starting nginx. nginx: [error] lua_load_resty_core failed to load the resty.core module from https://github.com/openresty/lua-resty-core; ensure you are using an OpenResty release from https://openresty.org/en/download.html (rc: 2, reason: module 'resty.core' not found: no field package.preload['resty.core'] no file './resty/core.lua' no file '/usr/local/share/luajit-2.1.0-beta3/resty/core.lua' no file '/usr/local/share/lua/5.1/resty/core.lua' no file '/usr/local/share/lua/5.1/resty/core/init.lua' no file './resty/core.so' no file '/usr/local/lib/lua/5.1/resty/core.so' no file '/usr/local/lib/lua/5.1/loadall.so' no file './resty.so' no file '/usr/local/lib/lua/5.1/resty.so' no file '/usr/local/lib/lua/5.1/loadall.so') [tsr@webproxy3 ~]$
You also need the two ports in https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=240160
Created attachment 207542 [details] www_nginx_Makefile_extmod.patch Please see attached patch. This will reduce the amount of incidental foot-shooting by approximately 100% by adding a dependency on www/lua-resty-core (which was added <looks> yesterday!) I have tested locally and it compiles cleanly with no issues AND keeps me from picking toes up off the floor.
Can confirm, all issues gone after www/lua-resty-core was installed.
(In reply to Thomas Steen Rasmussen / Tykling from comment #2) Can you confirm that everything's okay?: (In reply to Philipp Engel from comment #5)
I can confirm that adding www/lua-resty-core makes the problem go away!
We still need a commit to add the patch with the www/lua-resty-core dep to the ports tree, right? Or am I missing something?
This patch never got committed, right?
A commit references this bug: Author: mm Date: Sat Nov 16 09:41:09 UTC 2019 New revision: 517734 URL: https://svnweb.freebsd.org/changeset/ports/517734 Log: lua-nginx-module requires lua-resty-core (and lrucache) on runtime PR: 240274 Submitted by: Thomas Steen Rasmussen / Tykling <thomas@gibfest.dk> Reviewed by: mm@FreeBSD.org Approved by: maintainer timeout Changes: head/www/nginx/Makefile.extmod
A commit references this bug: Author: osa Date: Sat Nov 16 17:57:40 UTC 2019 New revision: 517767 URL: https://svnweb.freebsd.org/changeset/ports/517767 Log: Merge r517734 revision from www/nginx. Bump PORTREVISION. PR: 240274 Changes: head/www/nginx-devel/Makefile head/www/nginx-devel/Makefile.extmod