Skip to content

Commit 08d499b

Browse files
committed
feat(docker): support ARM architecture deployment
1 parent 930a96c commit 08d499b

File tree

1 file changed

+33
-0
lines changed

1 file changed

+33
-0
lines changed

docker/arm64/Dockerfile

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
FROM arm64v8/eclipse-temurin:17
2+
3+
ENV TMP_DIR="/tron-build"
4+
ENV BASE_DIR="/java-tron"
5+
6+
RUN set -o errexit -o nounset \
7+
&& apt-get update \
8+
&& apt-get -y install git p7zip-full wget libtcmalloc-minimal4 \
9+
&& echo "git clone" \
10+
&& mkdir -p $TMP_DIR \
11+
&& cd $TMP_DIR \
12+
&& git clone https://github.com/halibobo1205/java-tron.git \
13+
&& cd java-tron \
14+
&& git checkout arch/arm64 \
15+
&& ./gradlew clean build -x test -x check --no-daemon \
16+
&& cd build/distributions \
17+
&& 7za x -y java-tron-1.0.0.zip \
18+
&& mv java-tron-1.0.0 $BASE_DIR \
19+
&& rm -rf $TMP_DIR \
20+
&& rm -rf ~/.gradle \
21+
&& apt-get clean \
22+
&& rm -rf /var/lib/apt/lists/*
23+
24+
ENV LD_PRELOAD="/usr/lib/aarch64-linux-gnu/libtcmalloc_minimal.so.4"
25+
ENV TCMALLOC_RELEASE_RATE=10
26+
27+
RUN wget -P $BASE_DIR/config https://raw.githubusercontent.com/tronprotocol/tron-deployment/master/main_net_config.conf
28+
29+
COPY docker-entrypoint.sh $BASE_DIR/bin
30+
31+
WORKDIR $BASE_DIR
32+
33+
ENTRYPOINT ["./bin/docker-entrypoint.sh"]

0 commit comments

Comments
 (0)