From 108d52fdb12b9987a051ee5b76d8672b31d8adcd Mon Sep 17 00:00:00 2001 From: halibobo1205 Date: Wed, 4 Dec 2024 15:03:15 +0800 Subject: [PATCH] feat(docker): support ARM architecture deployment --- docker/arm64/Dockerfile | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 docker/arm64/Dockerfile diff --git a/docker/arm64/Dockerfile b/docker/arm64/Dockerfile new file mode 100644 index 00000000000..867a021cd1c --- /dev/null +++ b/docker/arm64/Dockerfile @@ -0,0 +1,30 @@ +FROM amazoncorretto:17.0.13 + +ENV TMP_DIR="/tron-build" +ENV BASE_DIR="/java-tron" +ENV UNZIP_DISABLE_ZIPBOMB_DETECTION=TRUE + + +RUN set -o errexit -o nounset \ + && yum -y install git unzip wget \ + && echo "git clone" \ + && mkdir -p $TMP_DIR \ + && cd $TMP_DIR \ + && git clone https://github.com/tronprotocol/java-tron.git \ + && cd java-tron \ + && git checkout master \ + && ./gradlew build -x test \ + && cd build/distributions \ + && unzip -o java-tron-1.0.0.zip \ + && mv java-tron-1.0.0 $BASE_DIR \ + && rm -rf $TMP_DIR \ + && rm -rf ~/.gradle \ + && yum clean all + +RUN wget -P $BASE_DIR/config https://raw.githubusercontent.com/tronprotocol/tron-deployment/master/main_net_config.conf + +COPY docker-entrypoint.sh $BASE_DIR/bin + +WORKDIR $BASE_DIR + +ENTRYPOINT ["./bin/docker-entrypoint.sh"] \ No newline at end of file