-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: use openssl111 in openresty dir in precedence #3603
Conversation
doc/install-dependencies.md
Outdated
@@ -39,6 +39,8 @@ | |||
|
|||
- On some platforms, installing LuaRocks via the package manager will cause Lua to be upgraded to Lua 5.3, so we recommend installing LuaRocks via source code. if you install OpenResty and its OpenSSL develop library (openresty-openssl-devel for rpm and openresty-openssl-dev for deb) via the official repository, then [we provide a script for automatic installation](../utils/linux-install-luarocks.sh). If you compile OpenResty yourself, you can refer to the above script and change the path in it. If you don't specify the OpenSSL library path when you compile, you don't need to configure the OpenSSL variables in LuaRocks, because the system's OpenSSL is used by default. If the OpenSSL library is specified at compile time, then you need to ensure that LuaRocks' OpenSSL configuration is consistent with OpenResty's. | |||
|
|||
- If you are using OpenResty/1.17.8 or higher version, please installing openresty-openssl111-devel instead of openresty-openssl-devel. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should warn for low version instead.
And also update the CI scripts.
And also update the Chinese doc.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You mean the low version of OpenResty?
Also, Do we still need to update the Chinese?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should install openresty-openssl111-devel by default and install openresty-openssl-devel for OpenResty 1.15.8.
And we need to update the Chinese docs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if we only support > openresty 1.17.8.1
, can it be easier?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, but we have a transition time, for now, we still need this.
more docs need to be updated: https://github.com/apache/apisix/blob/master/doc/install-dependencies.md#centos-7 |
Do you view the file on my branch? It was updated already. |
We need to update |
The change belongs to the dependencies installation, which is covered in the install-dependencies.md, Is there anything should also be change there? |
utils/linux-install-openresty.sh
Outdated
if [ "$OPENRESTY_VERSION" == "default" ]; then | ||
sudo apt-get install openresty-openssl111-debug-dev | ||
else | ||
verlt $OPENRESTY_VERSION 1.17.8.1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can simply check if the version is 1.15.8.2
so there is no need to comment out set -euo pipefail
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed.
sudo apt-get install "$openresty" lua5.1 liblua5.1-0-dev openresty-openssl-debug-dev | ||
sudo apt-get install "$openresty" lua5.1 liblua5.1-0-dev | ||
|
||
if [ "$OPENRESTY_VERSION" == "1.15.8.2" ]; then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We will not support version 1.15.8.2 soon.
all fine now. thanks for your explaining |
What this PR does / why we need it:
We use luasec since 5399a31, however, it uses the openssl libs and headers to compile itself, currently, we set two variables
$OPENSSL_LIBDIR
(e.g./usr/local/openresty/openssl/lib
) and$OPENSSL_INCDIR
(e.g./usr/local/openresty/openssl/include
).However, OpenResty 1.17.8 or higher version actually uses
openssl111
as the dir name of openssl. So in this PR, we detect the existence of diropenssl111
and use it in precedence.Pre-submission checklist: