github.com/shyftnetwork/go-empyrean@v1.8.3-0.20191127201940-fbfca9338f04/swarm/docker/Dockerfile (about)

     1  FROM golang:1.11-alpine as builder
     2  
     3  ARG VERSION
     4  
     5  RUN apk add --update git gcc g++ linux-headers
     6  RUN mkdir -p $GOPATH/src/github.com/ethereum && \
     7      cd $GOPATH/src/github.com/ethereum && \
     8      git clone https://github.com/ethersphere/go-ethereum && \
     9      cd $GOPATH/src/github.com/ethereum/go-ethereum && \
    10      git checkout ${VERSION} && \
    11      go install -ldflags "-X main.gitCommit=${VERSION}" ./cmd/swarm && \
    12      go install -ldflags "-X main.gitCommit=${VERSION}" ./cmd/swarm/swarm-smoke && \
    13      go install -ldflags "-X main.gitCommit=${VERSION}" ./cmd/geth && \
    14      cp $GOPATH/bin/swarm /swarm && cp $GOPATH/bin/geth /geth && cp $GOPATH/bin/swarm-smoke /swarm-smoke
    15  
    16  
    17  # Release image with the required binaries and scripts
    18  FROM alpine:3.8
    19  WORKDIR /
    20  COPY --from=builder /swarm /geth /swarm-smoke /
    21  ADD run.sh /run.sh
    22  ADD run-smoke.sh /run-smoke.sh
    23  ENTRYPOINT ["/run.sh"]