You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by sp...@apache.org on 2021/05/10 13:23:11 UTC
[apisix] branch master updated: ci: revert luarocks retry (#4038)
This is an automated email from the ASF dual-hosted git repository.
spacewander pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/apisix.git
The following commit(s) were added to refs/heads/master by this push:
new 504cd1b ci: revert luarocks retry (#4038)
504cd1b is described below
commit 504cd1b0966880101b3e2582cfb1cf65f23a7863
Author: Shuyang Wu <wo...@gmail.com>
AuthorDate: Mon May 10 09:23:03 2021 -0400
ci: revert luarocks retry (#4038)
---
.github/workflows/fuzzing-ci.yaml | 8 +-------
ci/centos7-ci.sh | 8 +-------
ci/common.sh | 8 +-------
ci/linux_apisix_current_luarocks_runner.sh | 9 +--------
ci/linux_apisix_master_luarocks_runner.sh | 10 +---------
utils/install-apisix.sh | 20 ++++++--------------
6 files changed, 11 insertions(+), 52 deletions(-)
diff --git a/.github/workflows/fuzzing-ci.yaml b/.github/workflows/fuzzing-ci.yaml
index 4b3299c..259f62b 100644
--- a/.github/workflows/fuzzing-ci.yaml
+++ b/.github/workflows/fuzzing-ci.yaml
@@ -51,13 +51,7 @@ jobs:
sudo apt-get install -y git openresty curl openresty-openssl111-dev unzip make gcc
sudo ./utils/linux-install-luarocks.sh
- for (( i = 0; i < 10; i++ )); do
- if [[ "$i" -eq 10 ]]; then
- echo "failed to make deps in time"
- exit 1
- fi
- make deps && break
- done
+ make deps
make init
make run
diff --git a/ci/centos7-ci.sh b/ci/centos7-ci.sh
index b03d4d2..779f4a3 100755
--- a/ci/centos7-ci.sh
+++ b/ci/centos7-ci.sh
@@ -59,13 +59,7 @@ install_dependencies() {
# install dependencies
git clone https://github.com/iresty/test-nginx.git test-nginx
- for (( i = 0; i < 10; i++ )); do
- if [[ "$i" -eq 10 ]]; then
- echo "failed to make deps in time"
- exit 1
- fi
- make deps && break
- done
+ make deps
}
run_case() {
diff --git a/ci/common.sh b/ci/common.sh
index 26e7b6f..a6b7814 100644
--- a/ci/common.sh
+++ b/ci/common.sh
@@ -26,13 +26,7 @@ export_or_prefix() {
create_lua_deps() {
echo "Create lua deps"
- for (( i = 0; i < 10; i++ )); do
- if [[ "$i" -eq 10 ]]; then
- echo "failed to make deps in time"
- exit 1
- fi
- make deps && break
- done
+ make deps
# maybe reopen this feature later
# luarocks install luacov-coveralls --tree=deps --local > build.log 2>&1 || (cat build.log && exit 1)
}
diff --git a/ci/linux_apisix_current_luarocks_runner.sh b/ci/linux_apisix_current_luarocks_runner.sh
index 5989c66..e055c4c 100755
--- a/ci/linux_apisix_current_luarocks_runner.sh
+++ b/ci/linux_apisix_current_luarocks_runner.sh
@@ -33,14 +33,7 @@ script() {
sudo rm -rf /usr/local/apisix
# install APISIX with local version
- for (( i = 0; i < 10; i++ )); do
- if [[ "$i" -eq 10 ]]; then
- echo "failed to install in time"
- cat build.log && exit 1
- exit 1
- fi
- sudo luarocks install rockspec/apisix-master-0.rockspec --only-deps > build.log 2>&1 && break
- done
+ sudo luarocks install rockspec/apisix-master-0.rockspec --only-deps > build.log 2>&1 || (cat build.log && exit 1)
sudo luarocks make rockspec/apisix-master-0.rockspec > build.log 2>&1 || (cat build.log && exit 1)
mkdir cli_tmp && cd cli_tmp
diff --git a/ci/linux_apisix_master_luarocks_runner.sh b/ci/linux_apisix_master_luarocks_runner.sh
index f0f14a4..c889ed2 100755
--- a/ci/linux_apisix_master_luarocks_runner.sh
+++ b/ci/linux_apisix_master_luarocks_runner.sh
@@ -53,15 +53,7 @@ script() {
sudo PATH=$PATH ./utils/install-apisix.sh remove > build.log 2>&1 || (cat build.log && exit 1)
# install APISIX by luarocks
- for (( i = 0; i < 10; i++ )); do
- if [[ "$i" -eq 10 ]]; then
- echo "failed to fetch lua rocks in time"
- cat build.log && exit 1
- exit 1
- fi
- sudo luarocks install $APISIX_MAIN > build.log 2>&1 && break
- i=$(( i + 1 ))
- done
+ sudo luarocks install $APISIX_MAIN > build.log 2>&1 || (cat build.log && exit 1)
cp ../bin/apisix /usr/local/bin/apisix
# show install files
diff --git a/utils/install-apisix.sh b/utils/install-apisix.sh
index 91e0142..92a3dd6 100755
--- a/utils/install-apisix.sh
+++ b/utils/install-apisix.sh
@@ -42,20 +42,12 @@ echo $UNAME
do_install() {
- i=0
- while true; do
- if [ "$i" = "10" ]; then
- echo "failed to install in time"
- cat build.log && exit 1
- exit 1
- fi
- if [ "$LUAROCKS_VER" = 'luarocks 3.' ]; then
- sudo luarocks install --lua-dir=$LUA_JIT_DIR $APISIX_VER --tree=/usr/local/apisix/deps --local > build.log 2>&1 && break
- else
- sudo luarocks install $APISIX_VER --tree=/usr/local/apisix/deps --local > build.log 2>&1 && break
- fi
- i=$(( i + 1 ))
- done
+ if [ "$LUAROCKS_VER" = 'luarocks 3.' ]; then
+ sudo luarocks install --lua-dir=$LUA_JIT_DIR $APISIX_VER --tree=/usr/local/apisix/deps --local
+
+ else
+ sudo luarocks install $APISIX_VER --tree=/usr/local/apisix/deps --local
+ fi
sudo rm -f /usr/bin/apisix
sudo ln -s /usr/local/apisix/deps/bin/apisix /usr/bin/apisix