plugeth-statediff/Dockerfile
Thomas E Lackey 94ec8c2436
Some checks failed
Test / Run unit tests (pull_request) Failing after 55s
Test / Run integration tests (pull_request) Failing after 3m21s
Try workaround for proxy issue.
2023-07-10 13:50:06 -05:00

23 lines
643 B
Docker

# Using the same base golang image as geth
FROM golang:1.20-alpine as builder
RUN apk add --no-cache gcc musl-dev binutils-gold linux-headers git
# Configure creds for gitea
ARG GIT_VDBTO_TOKEN
# Get and cache deps
WORKDIR /plugeth-statediff/
COPY go.mod go.sum .
RUN [ -n "$GIT_VDBTO_TOKEN" ] && \
GOPROXY=off git config --global url."https://$GIT_VDBTO_TOKEN@git.vdb.to/".insteadOf "https://git.vdb.to/" ; \
go mod download ; \
rm -f ~/.gitconfig
COPY . .
RUN go build --tags linkgeth --buildmode=plugin --trimpath -o statediff.so ./main
FROM alpine:3.18
COPY --from=builder /plugeth-statediff/statediff.so /usr/local/lib/