Files
ethereum-rpc-docker/base/Dockerfile
Sebastian 8e34db7740 update
2024-03-17 15:00:32 +01:00

46 lines
1.1 KiB
Docker

FROM golang:1.21 as op
WORKDIR /app
ENV REPO=https://github.com/ethereum-optimism/optimism.git
ENV VERSION=v1.7.1
# for verification:
ENV COMMIT=c87a469d7d679e8a4efbace56c3646b925bcc009
RUN git clone $REPO --branch op-node/$VERSION --single-branch . && \
git switch -c branch-$VERSION && \
bash -c '[ "$(git rev-parse HEAD)" = "$COMMIT" ]'
RUN cd op-node && \
make op-node
FROM golang:1.21 as geth
WORKDIR /app
ENV REPO=https://github.com/ethereum-optimism/op-geth.git
ENV VERSION=v1.101308.2
# for verification:
ENV COMMIT=0402d543c3d0cff3a3d344c0f4f83809edb44f10
# avoid depth=1, so the geth build can read tags
RUN git clone $REPO --branch $VERSION --single-branch . && \
git switch -c branch-$VERSION && \
bash -c '[ "$(git rev-parse HEAD)" = "$COMMIT" ]'
RUN go run build/ci.go install -static ./cmd/geth
FROM golang:1.21
RUN apt-get update && \
apt-get install -y jq curl && \
rm -rf /var/lib/apt/lists
WORKDIR /app
COPY --from=op /app/op-node/bin/op-node ./
COPY --from=geth /app/build/bin/geth ./
COPY geth-entrypoint .
COPY op-node-entrypoint .
COPY goerli ./goerli
COPY mainnet ./mainnet