11# docker build . -t cosmoscontracts/juno:latest
22# docker run --rm -it cosmoscontracts/juno:latest /bin/sh
3- FROM golang:1.19 -alpine3.15 AS go-builder
3+ FROM golang:1.18 -alpine3.15 AS go-builder
44
55# this comes from standard alpine nightly file
66# https://github.com/rust-lang/docker-rust-nightly/blob/master/alpine3.12/Dockerfile
77# with some changes to support our toolchain, etc
8+ SHELL ["/bin/ash" , "-eo" , "pipefail" , "-c" ]
9+ # we probably want to default to latest and error
10+ # since this is predominantly for dev use
11+ # hadolint ignore=DL3018
812RUN set -eux; apk add --no-cache ca-certificates build-base;
913
14+ # hadolint ignore=DL3018
1015RUN apk add git
1116# NOTE: add these to run with LEDGER_ENABLED=true
1217# RUN apk add libusb-dev linux-headers
@@ -21,12 +26,14 @@ RUN sha256sum /lib/libwasmvm_muslc.aarch64.a | grep 7d2239e9f25e96d0d4daba982ce9
2126RUN sha256sum /lib/libwasmvm_muslc.x86_64.a | grep f6282df732a13dec836cda1f399dd874b1e3163504dbd9607c6af915b2740479
2227
2328# Copy the library you want to the final location that will be found by the linker flag `-lwasmvm_muslc`
24- RUN cp /lib/libwasmvm_muslc.$(uname -m).a /lib/libwasmvm_muslc.a
29+ RUN cp " /lib/libwasmvm_muslc.$(uname -m).a" /lib/libwasmvm_muslc.a
2530
2631# force it to use static lib (from above) not standard libgo_cosmwasm.so file
27- RUN LEDGER_ENABLED=false BUILD_TAGS=muslc LINK_STATICALLY=true make build
28- RUN file /code/bin/junod
29- RUN echo "Ensuring binary is statically linked ..." \
32+ # then log output of file /code/bin/junod
33+ # then ensure static linking
34+ RUN LEDGER_ENABLED=false BUILD_TAGS=muslc LINK_STATICALLY=true make build \
35+ && file /code/bin/junod \
36+ && echo "Ensuring binary is statically linked ..." \
3037 && (file /code/bin/junod | grep "statically linked" )
3138
3239# --------------------------------------------------------
0 commit comments