shibarium: build bor + heimdall from source (no published images)
shibaone ships no docker images for the bone fork — only source + .deb config
packages — so both Dockerfiles must clone+build, not FROM a (nonexistent) image.
- bor.Dockerfile: clone shibaone/bor@${BOR_VERSION}, make bor, cp build/bin/bor
(was: alpine + wrong /src/build/bor path). golang:1.22.1 like upstream.
- cometbft.Dockerfile: clone shibaone/heimdall@${CL_VERSION}, make install
(was: FROM shibaone/heimdall:v1.0.7-bone — that tag does not exist on any
registry), then layer the CometBFT init entrypoint.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -1,38 +1,33 @@
|
||||
# Shibarium bor execution client Dockerfile
|
||||
# Build from shibaone/bor source repository.
|
||||
# Shibarium bor execution client — BUILT FROM SOURCE.
|
||||
#
|
||||
# shibaone publishes NO bor docker image (and vanilla 0xpolygon/bor is the WRONG
|
||||
# fork — Polygon, chainId 137). We mirror the upstream shibaone/bor Dockerfile
|
||||
# (`make bor` -> build/bin/bor) but clone the pinned tag so the image is
|
||||
# self-contained. Running `bor server --chain=shibarium` self-configures the
|
||||
# shibarium genesis (builder/files/genesis-shibarium.json, chainId 109) and the
|
||||
# bootnodes bundled in builder/files/config.toml.
|
||||
#
|
||||
# Build args:
|
||||
# BOR_REPO - repository URL (default: https://github.com/shibaone/bor)
|
||||
# BOR_VERSION - version tag (default: v1.3.9-bone)
|
||||
#
|
||||
# The shibaone/bor repo has a working Dockerfile that builds via `make bor`.
|
||||
# ENTRYPOINT is `bor`
|
||||
#
|
||||
# This Dockerfile is used for building shibarium bor from source,
|
||||
# as shibaone does not publish pre-built Docker images to Docker Hub.
|
||||
# BOR_REPO - bor source repo (default: https://github.com/shibaone/bor)
|
||||
# BOR_VERSION - bor version tag (passed by the template, e.g. v1.3.9-bone)
|
||||
|
||||
ARG BOR_REPO=https://github.com/shibaone/bor
|
||||
ARG BOR_VERSION=v1.3.9-bone
|
||||
|
||||
# Use a Go builder image to clone and build bor from source
|
||||
FROM golang:1.21-alpine AS builder
|
||||
FROM golang:1.22.1
|
||||
|
||||
RUN apk add --no-cache git make gcc musl-dev
|
||||
ARG BOR_REPO
|
||||
ARG BOR_VERSION
|
||||
|
||||
WORKDIR /src
|
||||
RUN git clone --depth 1 --branch ${BOR_VERSION} ${BOR_REPO} .
|
||||
RUN apt-get update -y && apt-get upgrade -y \
|
||||
&& apt-get install -y --no-install-recommends build-essential git ca-certificates \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
RUN make bor
|
||||
WORKDIR /var/lib/bor
|
||||
RUN git clone --depth 1 --branch ${BOR_VERSION} ${BOR_REPO} . \
|
||||
&& make bor \
|
||||
&& cp build/bin/bor /usr/bin/
|
||||
|
||||
# Final stage: copy the built binary
|
||||
FROM alpine:3.18
|
||||
|
||||
WORKDIR /usr/local/bin
|
||||
COPY --from=builder /src/build/bor /usr/local/bin/bor
|
||||
|
||||
# Create data directory
|
||||
RUN mkdir -p /root/.bor
|
||||
|
||||
WORKDIR /root/.bor
|
||||
|
||||
EXPOSE 8545 8546 8547 30303 30303/udp
|
||||
ENTRYPOINT ["bor"]
|
||||
|
||||
Reference in New Issue
Block a user