-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
43 lines (32 loc) · 892 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
FROM ubuntu:20.04 as builder
RUN set -ex; \
apt-get update; \
apt-get install -y --no-install-recommends \
git \
curl \
patch \
openjdk-8-jdk-headless \
; \
rm -rf /var/lib/apt/lists/*
RUN useradd -m -u 1000 -s /bin/bash tron
USER tron
ARG VERSION
RUN set -ex; \
git clone --depth 1 -b GreatVoyage-v${VERSION} https://github.com/tronprotocol/java-tron.git /home/tron/tron
RUN set -ex; \
cd /home/tron/tron; \
./gradlew build -x test
FROM ubuntu:20.04
RUN set -ex; \
apt-get update; \
apt-get install -y --no-install-recommends \
curl \
patch \
openjdk-8-jre-headless \
; \
rm -rf /var/lib/apt/lists/*
COPY --from=builder /home/tron/tron/build/libs/FullNode.jar /opt/
RUN curl -o /opt/config.conf -L https://raw.githubusercontent.com/tronprotocol/TronDeployment/master/main_net_config.conf
RUN useradd -m -u 1000 -s /bin/bash tron
USER tron
WORKDIR /opt