forked from Consensys/quorum-docker-Nnodes
/
Dockerfile
71 lines (57 loc) · 2 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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
FROM ubuntu:16.04 as builder
ARG CONSTELLATION_VERSION=0.3.2
WORKDIR /work
RUN apt-get update && \
apt-get install -y \
build-essential \
git \
libdb-dev \
libsodium-dev \
libtinfo-dev \
sysvbanner \
unzip \
wget \
wrk \
zlib1g-dev
RUN wget -q https://github.com/jpmorganchase/constellation/releases/download/v$CONSTELLATION_VERSION/constellation-$CONSTELLATION_VERSION-ubuntu1604.tar.xz && \
tar -xvf constellation-$CONSTELLATION_VERSION-ubuntu1604.tar.xz && \
cp constellation-$CONSTELLATION_VERSION-ubuntu1604/constellation-node /usr/local/bin && \
chmod 0755 /usr/local/bin/constellation-node && \
rm -rf constellation-$CONSTELLATION_VERSION-ubuntu1604.tar.xz constellation-$CONSTELLATION_VERSION-ubuntu1604
ENV GOREL go1.7.3.linux-amd64.tar.gz
ENV PATH $PATH:/usr/local/go/bin
RUN wget -q https://storage.googleapis.com/golang/$GOREL && \
tar xfz $GOREL && \
mv go /usr/local/go && \
rm -f $GOREL
COPY ./ /work/env
RUN cd env/quorum && \
make all && \
cp build/bin/geth /usr/local/bin && \
cp build/bin/bootnode /usr/local/bin && \
cd ../.. && \
rm -rf env
### Create the runtime image, leaving most of the cruft behind (hopefully...)
FROM ubuntu:16.04
# Install add-apt-repository
RUN apt-get update && \
apt-get install -y --no-install-recommends software-properties-common && \
add-apt-repository ppa:ethereum/ethereum && \
apt-get update && \
apt-get install -y --no-install-recommends \
libdb-dev \
libleveldb-dev \
libsodium-dev \
zlib1g-dev\
libtinfo-dev \
solc && \
rm -rf /var/lib/apt/lists/*
# Temporary useful tools
#RUN apt-get update && \
# apt-get install -y iputils-ping net-tools vim
COPY --from=builder \
/usr/local/bin/constellation-node \
/usr/local/bin/geth \
/usr/local/bin/bootnode \
/usr/local/bin/
CMD ["/qdata/start-node.sh"]