forked from graphsense/zec-client
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
39 lines (32 loc) · 1.29 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
33
34
35
36
37
38
39
FROM ubuntu:20.04 as builder
LABEL maintainer="[email protected]"
ARG VERSION=5.6.1
ENV TZ=UTC
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && \
echo $TZ > /etc/timezone && \
apt-get update && \
apt-get install --no-install-recommends -y \
apt-transport-https \
ca-certificates \
gnupg2 \
wget && \
wget -qO - https://apt.z.cash/zcash.asc | gpg2 --import && \
gpg2 --export B1C9095EAA1848DBB54D9DDA1D05FDC66B372CFE | apt-key add - && \
echo "deb [arch=amd64] https://apt.z.cash/ bullseye main" | tee /etc/apt/sources.list.d/zcash.list && \
apt-get update && \
apt-get install zcash=$VERSION
FROM ubuntu:20.04
ARG UID=10000
COPY --from=builder /usr/bin/zcash* /usr/local/bin/
ADD docker/client.conf /opt/graphsense/client.conf
RUN apt-get update && \
apt-get install --no-install-recommends -y wget ca-certificates && \
useradd -m -u $UID dockeruser && \
mkdir -p /opt/graphsense/data && \
chown dockeruser -R /opt/graphsense && \
zcash-fetch-params && \
mv /root/.zcash-params/ /home/dockeruser/.zcash-params && \
chown dockeruser:dockeruser /home/dockeruser/.zcash-params
USER dockeruser
EXPOSE 8632
CMD ["zcashd", "-conf=/opt/graphsense/client.conf", "-datadir=/opt/graphsense/data", "-rest", "-printtoconsole"]