From: Vladimír Čunát Date: Mon, 31 Aug 2020 07:29:44 +0000 (+0200) Subject: scripts, docs: specify lua version in `luarocks install` X-Git-Tag: v5.1.3~3^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=66b6352d2e5ab4d0c5891c1eaeff1cd8914fb2a3;p=thirdparty%2Fknot-resolver.git scripts, docs: specify lua version in `luarocks install` On some systems luarocks defaults to other lua version (e.g. Fedora), so the result would not be usable from kresd. I didn't touch scripts for older distro versions (Debian < 10, Ubuntu < 20.04, CentOS 7). --- diff --git a/ci/debian-buster/Dockerfile b/ci/debian-buster/Dockerfile index 1656ac56f..0d0527f8a 100644 --- a/ci/debian-buster/Dockerfile +++ b/ci/debian-buster/Dockerfile @@ -58,7 +58,7 @@ RUN wget https://github.com/LuaJIT/LuaJIT/raw/v2.1.0-beta3/src/lj.supp -O /lj.su # Lua lint for kresd CI RUN apt-get install luarocks -y -qqq -RUN luarocks install luacheck +RUN luarocks --lua-version 5.1 install luacheck # respdiff for kresd CI RUN apt-get install lmdb-utils -y -qqq @@ -89,7 +89,7 @@ RUN apt-get install pdns-recursor -y -qqq # code coverage RUN apt-get install -y -qqq lcov -RUN luarocks install luacov +RUN luarocks --lua-version 5.1 install luacov # LuaJIT binary for stand-alone scripting RUN apt-get install -y -qqq luajit diff --git a/modules/etcd/.packaging/debian/10/pre-test.sh b/modules/etcd/.packaging/debian/10/pre-test.sh index 4df79d999..20073dc8e 100755 --- a/modules/etcd/.packaging/debian/10/pre-test.sh +++ b/modules/etcd/.packaging/debian/10/pre-test.sh @@ -1 +1 @@ -luarocks install etcd --from=https://mah0x211.github.io/rocks/ +luarocks --lua-version 5.1 install etcd --from=https://mah0x211.github.io/rocks/ diff --git a/modules/etcd/.packaging/leap/15.2/pre-test.sh b/modules/etcd/.packaging/leap/15.2/pre-test.sh index 4df79d999..20073dc8e 100755 --- a/modules/etcd/.packaging/leap/15.2/pre-test.sh +++ b/modules/etcd/.packaging/leap/15.2/pre-test.sh @@ -1 +1 @@ -luarocks install etcd --from=https://mah0x211.github.io/rocks/ +luarocks --lua-version 5.1 install etcd --from=https://mah0x211.github.io/rocks/ diff --git a/modules/etcd/.packaging/ubuntu/20.04/pre-test.sh b/modules/etcd/.packaging/ubuntu/20.04/pre-test.sh index 4df79d999..20073dc8e 100755 --- a/modules/etcd/.packaging/ubuntu/20.04/pre-test.sh +++ b/modules/etcd/.packaging/ubuntu/20.04/pre-test.sh @@ -1 +1 @@ -luarocks install etcd --from=https://mah0x211.github.io/rocks/ +luarocks --lua-version 5.1 install etcd --from=https://mah0x211.github.io/rocks/ diff --git a/modules/etcd/README.rst b/modules/etcd/README.rst index 6e662fa95..567151d4c 100644 --- a/modules/etcd/README.rst +++ b/modules/etcd/README.rst @@ -42,5 +42,5 @@ Dependencies * `lua-etcd `_ library available in LuaRocks - ``$ luarocks install etcd --from=https://mah0x211.github.io/rocks/`` + ``$ luarocks --lua-version 5.1 install etcd --from=https://mah0x211.github.io/rocks/`` diff --git a/modules/experimental_dot_auth/.packaging/leap/15.2/pre-test.sh b/modules/experimental_dot_auth/.packaging/leap/15.2/pre-test.sh index 3c9f93256..df5d7845a 100755 --- a/modules/experimental_dot_auth/.packaging/leap/15.2/pre-test.sh +++ b/modules/experimental_dot_auth/.packaging/leap/15.2/pre-test.sh @@ -1 +1 @@ -luarocks install basexx --from=https://mah0x211.github.io/rocks/ +luarocks --lua-version 5.1 install basexx --from=https://mah0x211.github.io/rocks/ diff --git a/modules/graphite/.packaging/leap/15.2/pre-test.sh b/modules/graphite/.packaging/leap/15.2/pre-test.sh index 725e5fce8..9614066a3 100755 --- a/modules/graphite/.packaging/leap/15.2/pre-test.sh +++ b/modules/graphite/.packaging/leap/15.2/pre-test.sh @@ -1 +1 @@ -luarocks install cqueues --from=https://mah0x211.github.io/rocks/ +luarocks --lua-version 5.1 install cqueues --from=https://mah0x211.github.io/rocks/ diff --git a/modules/http/.packaging/leap/15.2/pre-test.sh b/modules/http/.packaging/leap/15.2/pre-test.sh index 6b98d7ee2..bb1e1311f 100755 --- a/modules/http/.packaging/leap/15.2/pre-test.sh +++ b/modules/http/.packaging/leap/15.2/pre-test.sh @@ -1 +1 @@ -luarocks install http --from=https://mah0x211.github.io/rocks/ +luarocks --lua-version 5.1 install http --from=https://mah0x211.github.io/rocks/ diff --git a/modules/http/README.rst b/modules/http/README.rst index ef74d1158..05ad0f3c8 100644 --- a/modules/http/README.rst +++ b/modules/http/README.rst @@ -152,17 +152,17 @@ Dependencies $ brew install openssl $ brew link openssl --force # Override system OpenSSL - Any other system can install from LuaRocks directly: + Some other systems can install from LuaRocks directly: .. code-block:: bash - $ luarocks install http + $ luarocks --lua-version 5.1 install http * (*optional*) `mmdblua `_ available in LuaRocks .. code-block:: bash - $ luarocks install --server=https://luarocks.org/dev mmdblua + $ luarocks --lua-version 5.1 install --server=https://luarocks.org/dev mmdblua $ curl -O https://geolite.maxmind.com/download/geoip/database/GeoLite2-City.mmdb.gz $ gzip -d GeoLite2-City.mmdb.gz