Skip to content

Commit b82ca5d

Browse files
committed
guard RLS_ARCH and push the filename intra-step
1 parent 75dad93 commit b82ca5d

1 file changed

Lines changed: 9 additions & 6 deletions

File tree

1.14.4/x86_64-bionic/Dockerfile

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,18 @@ WORKDIR /verify
66
ARG RLS_VERSION=1.14.4
77
ARG RLS_OS=linux
88
ARG RLS_LIB=gnu
9-
ARG RLS_ARCH=x86_64
9+
ARG RLS_ARCH=
1010

1111
# Automatically detect architecture
12-
RUN set -ex && ARCHITECTURE=$(dpkg --print-architecture) && \
13-
if [ "${ARCHITECTURE}" = "amd64" ]; then RLS_ARCH=x86_64 ; fi \
12+
RUN set -ex && ARCHITECTURE=$(dpkg --print-architecture) \
13+
&& if [ "${ARCHITECTURE}" = "amd64" ]; then RLS_ARCH=x86_64 ; fi \
1414
&& if [ "${ARCHITECTURE}" = "arm64" ]; then RLS_ARCH=aarch64; fi \
1515
&& if [ "${ARCHITECTURE}" = "armhf" ]; then RLS_ARCH=arm && RLS_LIB=gnuabihf; fi \
16-
&& if [ "${ARCHITECTURE}" = "i386" ]; then RLS_ARCH=i686-pc; fi
16+
&& if [ "${ARCHITECTURE}" = "i386" ]; then RLS_ARCH=i686-pc; fi \
17+
&& if [ "${RLS_ARCH}" = "" ]; then echo "Could not determine architecture"; exit 1; fi \
18+
&& RLS_FILE_NAME=dogecoin-${RLS_VERSION}-${RLS_ARCH}-${RLS_OS}-${RLS_LIB}.tar.gz \
19+
&& echo -n ${RLS_FILE_NAME} > .filename
1720

18-
ARG RLS_FILE_NAME=dogecoin-${RLS_VERSION}-${RLS_ARCH}-${RLS_OS}-${RLS_LIB}.tar.gz
1921
ARG SIG_PATH=${RLS_VERSION}-${RLS_OS}
2022
ARG DESCRIPTOR_PATH=dogecoin/contrib/gitian-descriptors/gitian-${RLS_OS}.yml
2123

@@ -39,7 +41,8 @@ RUN git clone --depth 1 ${REPO_GITIAN_BUILDER} gitian && \
3941
find dogecoin/contrib/gitian-keys -name "*.pgp" |xargs -n 1 gpg --import
4042

4143
# download release binary and verify against random signer
42-
RUN wget ${RLS_LOCATION}/${RLS_FILE_NAME} && \
44+
RUN RLS_FILE_NAME=`cat .filename` && \
45+
wget ${RLS_LOCATION}/${RLS_FILE_NAME} && \
4346
gitian/bin/gverify --no-markup -d sigs -r ${SIG_PATH} \
4447
${DESCRIPTOR_PATH} | grep OK | \
4548
shuf -n 1 | sed s/:.*// > random_signer.txt && \

0 commit comments

Comments
 (0)