From 9882eb4a8fa6fb014b4b951c9da11dfa9f1619bd Mon Sep 17 00:00:00 2001 From: DanyLE Date: Wed, 13 Mar 2024 18:42:33 +0100 Subject: [PATCH] feat: use antd http server v2.0.0 with all plugins updated --- Makefile | 18 ++++++---------- antd/ant-http | 2 +- antd/antd-fcgi-plugin | 2 +- antd/antd-tunnel-plugin | 2 +- antd/antd-wvnc-plugin | 2 +- antd/silk | 2 +- config/antd-config.ini | 1 - scripts/mkdocker.sh | 46 +++++++++++++++++++++++++++++++++++++++++ 8 files changed, 57 insertions(+), 18 deletions(-) create mode 100755 scripts/mkdocker.sh diff --git a/Makefile b/Makefile index 111d0e2..11f3271 100644 --- a/Makefile +++ b/Makefile @@ -61,7 +61,7 @@ plugins: antd-fcgi-plugin antd-tunnel-plugin antd-wvnc-plugin antd-tunnel-publis luasec: clean_c @echo "Building $@" - lua5.3 $(ROOT_DIR)/antd/luasec/src/options.lua -g \ + lua $(ROOT_DIR)/antd/luasec/src/options.lua -g \ /usr/include/openssl/ssl.h \ > $(ROOT_DIR)/antd/luasec/src/options.c CC=$(CC) \ @@ -100,7 +100,9 @@ luasocket: clean_c antd-% sil%: clean_c @echo "Building $@" cd $(ROOT_DIR)/antd/$@ && libtoolize && aclocal && autoconf && automake --add-missing - cd $(ROOT_DIR)/antd/$@ && CFLAGS="-I$(INSTALL_DIR)/include" LDFLAGS="-L$(INSTALL_DIR)/lib" \ + cd $(ROOT_DIR)/antd/$@ && \ + CFLAGS="-I$(INSTALL_DIR)/include"\ + LDFLAGS="-L$(INSTALL_DIR)/lib" \ ./configure $(HOST) --prefix=$(BUILD_PREFIX) DESTDIR=$(BUILDDIR)/$(ARCH) make -C $(ROOT_DIR)/antd/$@ install @@ -178,15 +180,7 @@ appimg: scripts/mkappimg.sh $(ARCH) $(VERSION_STR) $(BUILDDIR)/$(ARCH) $(ROOT_DIR)/antos-64.png docker: - ln -sfn arm $(BUILDDIR)/armv7l - ln -sfn arm64 $(BUILDDIR)/aarch64 - ln -sfn amd64 $(BUILDDIR)/x86_64 - docker buildx build \ - --platform linux/arm/v7,linux/arm64/v8,linux/amd64 \ - --tag $(DOCKER_IMAGE):$(DOCKER_TAG) \ - -f docker/antos/Dockerfile \ - --push \ - . - rm $(BUILDDIR)/aarch64 $(BUILDDIR)/armv7l $(BUILDDIR)/x86_64 + scripts/mkdocker.sh $(DOCKER_IMAGE):$(DOCKER_TAG) + # --push .PHONY: antd antos docker \ No newline at end of file diff --git a/antd/ant-http b/antd/ant-http index 32552ee..58a7738 160000 --- a/antd/ant-http +++ b/antd/ant-http @@ -1 +1 @@ -Subproject commit 32552ee0ed78fd76b8c8524280d3d07d9f3d1ab7 +Subproject commit 58a7738afee006a1a816bfab15ae54e879eb723a diff --git a/antd/antd-fcgi-plugin b/antd/antd-fcgi-plugin index bfa6020..6a82a98 160000 --- a/antd/antd-fcgi-plugin +++ b/antd/antd-fcgi-plugin @@ -1 +1 @@ -Subproject commit bfa6020ce271ed8f3a3d28761fd1bcfef494c394 +Subproject commit 6a82a98aa5e7dfb7d274151260f4b33111229a77 diff --git a/antd/antd-tunnel-plugin b/antd/antd-tunnel-plugin index 8da0bf3..de2c072 160000 --- a/antd/antd-tunnel-plugin +++ b/antd/antd-tunnel-plugin @@ -1 +1 @@ -Subproject commit 8da0bf39340f78410e6419876bd6c18bc8eb93ca +Subproject commit de2c072d6df07840784274797bf5bfaaefb8fda1 diff --git a/antd/antd-wvnc-plugin b/antd/antd-wvnc-plugin index 6c1df8e..d08ae89 160000 --- a/antd/antd-wvnc-plugin +++ b/antd/antd-wvnc-plugin @@ -1 +1 @@ -Subproject commit 6c1df8e4d558fd88d94f3a78a504c922b4b2aa13 +Subproject commit d08ae89c82232c53c63c658c7ab26175440702a6 diff --git a/antd/silk b/antd/silk index bf5284e..6380787 160000 --- a/antd/silk +++ b/antd/silk @@ -1 +1 @@ -Subproject commit bf5284e66f4631e10488884e5bd22d4ac2407810 +Subproject commit 6380787d7e0ba67146a0a9343675aac5c8c12aec diff --git a/config/antd-config.ini b/config/antd-config.ini index a20487f..8b3d852 100644 --- a/config/antd-config.ini +++ b/config/antd-config.ini @@ -1,7 +1,6 @@ [SERVER] plugins=/opt/www/lib/ plugins_ext=.so -database=/opt/www/database/ tmpdir=/tmp/ maxcon=500 backlog=5000 diff --git a/scripts/mkdocker.sh b/scripts/mkdocker.sh new file mode 100755 index 0000000..6751bbf --- /dev/null +++ b/scripts/mkdocker.sh @@ -0,0 +1,46 @@ +#!/bin/bash + +set -e + +DOCKER_IMAGE=$1 + +if [ -z "$DOCKER_IMAGE" ]; then + echo "Please provide : as parameter" + exit 1 +fi + +rm build/aarch64 build/armv7l build/x86_64 || true + +list=$(ls build/) + +platforms= + +for item in $list; do + case $item in + amd64) + platforms="$platforms,linux/amd64" + ;; + arm64) + platforms="$platforms,linux/arm64/v8" + ;; + arm) + platforms="$platforms,linux/arm/v7" + ;; + *) + echo "Unkown architecture $item" + exit 1 + ;; + esac +done +platforms=${platforms##,} +echo "Building docker image for the following platforms: $platforms" +ln -sfn arm build/armv7l +ln -sfn arm64 build/aarch64 +ln -sfn amd64 build/x86_64 + +docker buildx build \ + --platform "$platforms" \ + --tag "$DOCKER_IMAGE" \ + -f docker/antos/Dockerfile \ + --push \ + . \ No newline at end of file