This is an automated email from the ASF dual-hosted git repository.

shuyangw pushed a commit to branch revert-162-fix/broken-luarocks
in repository https://gitbox.apache.org/repos/asf/apisix-docker.git

commit 680cd95ec5dc52c2cfcb69ebfcb1b47d9ecbe43c
Author: Shuyang Wu <[email protected]>
AuthorDate: Sun May 9 22:39:13 2021 -0400

    Revert "fix: build failure caused by luarocks connection (#162)"
    
    This reverts commit cae84f92213dc6db59785146294f5fca3dc9e7ea.
---
 all-in-one/apisix-dashboard/Dockerfile | 2 +-
 all-in-one/apisix/Dockerfile           | 2 +-
 alpine-dev/Dockerfile                  | 2 +-
 alpine-local/Dockerfile                | 2 +-
 alpine/Dockerfile                      | 2 +-
 5 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/all-in-one/apisix-dashboard/Dockerfile 
b/all-in-one/apisix-dashboard/Dockerfile
index 32d163e..de9b9cd 100644
--- a/all-in-one/apisix-dashboard/Dockerfile
+++ b/all-in-one/apisix-dashboard/Dockerfile
@@ -22,7 +22,7 @@ RUN set -x \
     && mkdir ~/.luarocks \
     && luarocks config variables.OPENSSL_LIBDIR 
/usr/local/openresty/openssl/lib \
     && luarocks config variables.OPENSSL_INCDIR 
/usr/local/openresty/openssl/include \
-    && (i=0; while true; do if [[ "$i" -eq 10 ]]; then echo "failed to fetch 
Lua rocks in time"; exit 1; fi; luarocks install 
https://github.com/apache/apisix/raw/master/rockspec/apisix-${APISIX_VERSION}-0.rockspec
 --tree=/usr/local/apisix/deps && break; i=$(( i + 1 )); done;) \
+    && luarocks install 
https://github.com/apache/apisix/raw/master/rockspec/apisix-${APISIX_VERSION}-0.rockspec
 --tree=/usr/local/apisix/deps \
     && cp -v 
/usr/local/apisix/deps/lib/luarocks/rocks-5.1/apisix/${APISIX_VERSION}-0/bin/apisix
 /usr/bin/ \
     && (if [ "$APISIX_VERSION" = "master" ] || [ "$APISIX_VERSION" \> "2.2" ]; 
then echo 'use shell ';else bin='#! 
/usr/local/openresty/luajit/bin/luajit\npackage.path = 
"/usr/local/apisix/?.lua;" .. package.path'; sed -i "1s@.*@$bin@" 
/usr/bin/apisix ; fi;) \
     && mv /usr/local/apisix/deps/share/lua/5.1/apisix /usr/local/apisix \
diff --git a/all-in-one/apisix/Dockerfile b/all-in-one/apisix/Dockerfile
index 97ea86f..08ecf13 100644
--- a/all-in-one/apisix/Dockerfile
+++ b/all-in-one/apisix/Dockerfile
@@ -22,7 +22,7 @@ RUN set -x \
     && mkdir ~/.luarocks \
     && luarocks config variables.OPENSSL_LIBDIR 
/usr/local/openresty/openssl/lib \
     && luarocks config variables.OPENSSL_INCDIR 
/usr/local/openresty/openssl/include \
-    && (i=0; while true; do if [[ "$i" -eq 10 ]]; then echo "failed to fetch 
Lua rocks in time"; exit 1; fi; luarocks install 
https://github.com/apache/apisix/raw/master/rockspec/apisix-${APISIX_VERSION}-0.rockspec
 --tree=/usr/local/apisix/deps && break; i=$(( i + 1 )); done;) \
+    && luarocks install 
https://github.com/apache/apisix/raw/master/rockspec/apisix-${APISIX_VERSION}-0.rockspec
 --tree=/usr/local/apisix/deps \
     && cp -v 
/usr/local/apisix/deps/lib/luarocks/rocks-5.1/apisix/${APISIX_VERSION}-0/bin/apisix
 /usr/bin/ \
     && (if [ "$APISIX_VERSION" = "master" ] || [ "$APISIX_VERSION" \> "2.2" ]; 
then echo 'use shell ';else bin='#! 
/usr/local/openresty/luajit/bin/luajit\npackage.path = 
"/usr/local/apisix/?.lua;" .. package.path'; sed -i "1s@.*@$bin@" 
/usr/bin/apisix ; fi;) \
     && mv /usr/local/apisix/deps/share/lua/5.1/apisix /usr/local/apisix \
diff --git a/alpine-dev/Dockerfile b/alpine-dev/Dockerfile
index bfc3e18..0054eeb 100644
--- a/alpine-dev/Dockerfile
+++ b/alpine-dev/Dockerfile
@@ -15,7 +15,7 @@ RUN set -x \
     && mkdir ~/.luarocks \
     && luarocks config variables.OPENSSL_LIBDIR 
/usr/local/openresty/openssl/lib \
     && luarocks config variables.OPENSSL_INCDIR 
/usr/local/openresty/openssl/include \
-    && (i=0; while true; do if [[ "$i" -eq 10 ]]; then echo "failed to fetch 
Lua rocks in time"; exit 1; fi; luarocks install 
https://github.com/apache/apisix/raw/master/rockspec/apisix-master-0.rockspec 
--tree=/usr/local/apisix/deps && break; i=$(( i + 1 )); done;) \
+    && luarocks install 
https://github.com/apache/apisix/raw/master/rockspec/apisix-master-0.rockspec 
--tree=/usr/local/apisix/deps \
     && cp -v 
/usr/local/apisix/deps/lib/luarocks/rocks-5.1/apisix/master-0/bin/apisix 
/usr/bin/ \
     && mv /usr/local/apisix/deps/share/lua/5.1/apisix /usr/local/apisix \
     && apk del .builddeps build-base make unzip
diff --git a/alpine-local/Dockerfile b/alpine-local/Dockerfile
index cb812a5..e0f5e56 100644
--- a/alpine-local/Dockerfile
+++ b/alpine-local/Dockerfile
@@ -15,7 +15,7 @@ RUN set -x \
     cmake \
     git \
     && cd apisix \
-    && (i=0; while true; do if [[ "$i" -eq 10 ]]; then echo "failed to make 
deps in time"; exit 1; fi; make deps && break; i=$(( i + 1 )); done;) \
+    && make deps \
     && cp -v bin/apisix /usr/bin/ \
     && mv ../apisix /usr/local/apisix \
     && apk del .builddeps build-base make unzip
diff --git a/alpine/Dockerfile b/alpine/Dockerfile
index 90dc95e..63bd029 100644
--- a/alpine/Dockerfile
+++ b/alpine/Dockerfile
@@ -18,7 +18,7 @@ RUN set -x \
     && mkdir ~/.luarocks \
     && luarocks config variables.OPENSSL_LIBDIR 
/usr/local/openresty/openssl/lib \
     && luarocks config variables.OPENSSL_INCDIR 
/usr/local/openresty/openssl/include \
-    && (i=0; while true; do if [[ "$i" -eq 10 ]]; then echo "failed to fetch 
Lua rocks in time"; exit 1; fi; luarocks install 
https://github.com/apache/apisix/raw/master/rockspec/apisix-${APISIX_VERSION}-0.rockspec
 --tree=/usr/local/apisix/deps && break; i=$(( i + 1 )); done;) \
+    && luarocks install 
https://github.com/apache/apisix/raw/master/rockspec/apisix-${APISIX_VERSION}-0.rockspec
 --tree=/usr/local/apisix/deps \
     && cp -v 
/usr/local/apisix/deps/lib/luarocks/rocks-5.1/apisix/${APISIX_VERSION}-0/bin/apisix
 /usr/bin/ \
     && (if [ "$APISIX_VERSION" = "master" ] || [ "$APISIX_VERSION" \> "2.2" ]; 
then echo 'use shell ';else bin='#! 
/usr/local/openresty/luajit/bin/luajit\npackage.path = 
"/usr/local/apisix/?.lua;" .. package.path'; sed -i "1s@.*@$bin@" 
/usr/bin/apisix ; fi;) \
     && mv /usr/local/apisix/deps/share/lua/5.1/apisix /usr/local/apisix \

Reply via email to