-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathDockerfile.common.erb
More file actions
39 lines (36 loc) · 1.21 KB
/
Dockerfile.common.erb
File metadata and controls
39 lines (36 loc) · 1.21 KB
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
# Install suitable version of boost
<% if boost_version -%>
ENV BOOST_VERSION_D <%= boost_version %>
ENV BOOST_VERSION_U <%= boost_version.gsub(/\./, '_') %>
ENV BOOST_SHA256 <%= boost_sha256 %>
RUN set -ex \
&& cd ~ \
&& wget -qO boost.tgz "https://sourceforge.net/projects/boost/files/boost/$BOOST_VERSION_D/boost_$BOOST_VERSION_U.tar.gz/download" \
&& echo "$BOOST_SHA256 boost.tgz" | sha256sum -c - \
&& tar -xzf boost.tgz \
&& cd "boost_$BOOST_VERSION_U" \
&& ./bootstrap.sh --prefix=/usr/local \
&& ./b2 install
<% end -%>
# Setup ld search path
RUN set -ex \
&& ldconfig
ENV BITCOIN_VERSION <%= version %>
ENV BITCOIN_URL <%= url %>
ENV BITCOIN_SHA256 <%= sha256 %>
<% if asc_url -%>
ENV BITCOIN_ASC_URL <%= asc_url %>
ENV BITCOIN_PGP_KEY <%= key %>
<% end -%>
# Install bitcoin src
RUN set -ex \
&& cd /tmp \
&& wget -qO bitcoin.tar.gz "$BITCOIN_URL" \
&& echo "$BITCOIN_SHA256 bitcoin.tar.gz" | sha256sum -c - \
<% if asc_url -%>
&& gpg --no-tty --keyserver keyserver.ubuntu.com --recv-keys "$BITCOIN_PGP_KEY" \
&& wget -qO bitcoin.asc "$BITCOIN_ASC_URL" \
&& gpg --no-tty --verify bitcoin.asc \
<% end -%>
&& tar -xzvf bitcoin.tar.gz -C /opt \
&& rm -rf /tmp/*