forked from kannix/monero-full-node
-
Notifications
You must be signed in to change notification settings - Fork 3
/
Dockerfile.ubuntu
33 lines (21 loc) · 1.19 KB
/
Dockerfile.ubuntu
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
# Usage: docker run --restart=always -v /var/data/blockchain-xmr:/root/.bitmonero -p 18080:18080 -p 18081:18081 --name=monerod -td kannix/monero-full-node
FROM ubuntu:22.04 AS build
ENV MONERO_VERSION=0.18.1.2 MONERO_SHA256=7d51e7072351f65d0c7909e745827cfd3b00abe5e7c4cc4c104a3c9b526da07e
RUN apt-get update && apt-get install -y curl bzip2
WORKDIR /root
RUN curl https://dlsrc.getmonero.org/cli/monero-linux-x64-v$MONERO_VERSION.tar.bz2 -O &&\
echo "$MONERO_SHA256 monero-linux-x64-v$MONERO_VERSION.tar.bz2" | sha256sum -c - &&\
tar -xvf monero-linux-x64-v$MONERO_VERSION.tar.bz2 &&\
rm monero-linux-x64-v$MONERO_VERSION.tar.bz2 &&\
cp ./monero-x86_64-linux-gnu-v$MONERO_VERSION/monerod . &&\
rm -r monero-*
FROM ubuntu:22.04
RUN useradd -ms /bin/bash monero && mkdir -p /home/monero/.bitmonero && chown -R monero:monero /home/monero/.bitmonero
USER monero
WORKDIR /home/monero
COPY --chown=monero:monero --from=build /root/monerod /home/monero/monerod
# blockchain location
VOLUME /home/monero/.bitmonero
EXPOSE 18080 18081
ENTRYPOINT ["./monerod"]
CMD ["--non-interactive", "--restricted-rpc", "--rpc-bind-ip=0.0.0.0", "--confirm-external-bind", "--enable-dns-blocklist", "--out-peers=16"]