-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
32 lines (22 loc) · 1.05 KB
/
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
FROM ubuntu:bionic
RUN set -eux; \
apt-get update; \
apt-get install -y gosu curl; \
apt-get clean; \
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*; \
# Verify that gosu binary works
gosu nobody true
RUN groupadd --gid 1234 theta; \
useradd --uid 1234 --gid 1234 theta
RUN mkdir -p /theta_mainnet/bin /theta_mainnet/guardian_mainnet/node; \
curl -k --output /theta_mainnet/bin/theta `curl -k 'https://mainnet-data.thetatoken.org/binary?os=linux&name=theta'`; \
curl -k --output /theta_mainnet/guardian_mainnet/node/config.yaml `curl -k 'https://mainnet-data.thetatoken.org/config?is_guardian=true'`; \
chmod +x /theta_mainnet/bin/theta
RUN curl -k --output /theta_mainnet/bin/thetacli `curl -k 'https://mainnet-data.thetatoken.org/binary?os=linux&name=thetacli'`; \
chmod +x /theta_mainnet/bin/thetacli
ENV PATH="/theta_mainnet/bin/:${PATH}"
VOLUME ["/theta_mainnet/guardian_mainnet/node"]
EXPOSE 30001 16888
COPY docker-entrypoint.sh docker-entrypoint.sh
ENTRYPOINT ["./docker-entrypoint.sh"]
CMD ["theta", "--help"]