fixturenet-eth-stacks/stack-orchestrator/container-build/cerc-fixturenet-eth-genesis-premerge/Dockerfile

29 lines
1.0 KiB
Docker
Raw Normal View History

FROM skylenet/ethereum-genesis-generator@sha256:210353ce7c898686bc5092f16c61220a76d357f51eff9c451e9ad1b9ad03d4d3 AS ethgen
2024-04-25 12:23:30 +00:00
FROM golang:1.20-alpine as builder
RUN apk add --no-cache python3 py3-pip
COPY genesis /opt/genesis
2024-04-25 12:23:30 +00:00
# Install ethereum-genesis-generator tools
COPY --from=ethgen /usr/local/bin/eth2-testnet-genesis /usr/local/bin/
COPY --from=ethgen /usr/local/bin/eth2-val-tools /usr/local/bin/
2024-04-25 12:23:30 +00:00
COPY --from=ethgen /apps /apps
RUN cd /apps/el-gen && pip3 install --break-system-packages -r requirements.txt
# web3==5.24.0 used by el-gen is broken on python 3.11
RUN pip3 install --break-system-packages --upgrade "web3==6.5.0"
2024-04-25 12:23:30 +00:00
RUN pip3 install --break-system-packages --upgrade "typing-extensions"
# Build genesis config
RUN apk add --no-cache make bash envsubst jq
2024-04-25 12:23:30 +00:00
RUN cd /opt/genesis && make genesis-el
# Snag the genesis block info.
RUN go install github.com/cerc-io/eth-dump-genblock@latest
2024-04-25 12:23:30 +00:00
RUN eth-dump-genblock /opt/genesis/build/el/geth.json > /opt/genesis/build/el/genesis_block.json
FROM alpine:latest
COPY --from=builder /opt/genesis /opt/genesis