Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

proofs Add a proofs-tools docker image #11825

Merged
merged 7 commits into from
Sep 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 22 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1742,6 +1742,10 @@ workflows:
docker_name: op-challenger
docker_tags: <<pipeline.git.revision>>,<<pipeline.git.branch>>
save_image_tag: <<pipeline.git.revision>> # for devnet later
- docker-build:
name: proofs-tools-docker-build
docker_name: proofs-tools
docker_tags: <<pipeline.git.revision>>,<<pipeline.git.branch>>
- docker-build:
name: op-dispute-mon-docker-build
docker_name: op-dispute-mon
Expand Down Expand Up @@ -1978,10 +1982,10 @@ workflows:
requires:
- op-supervisor-docker-release
- docker-build:
name: ci-builder-docker-release
name: op-challenger-big-docker-release
filters:
tags:
only: /^ci-builder\/v.*/
only: /^op-challenger\/v.*/
branches:
ignore: /.*/
docker_name: ci-builder
Expand All @@ -1993,6 +1997,22 @@ workflows:
- oplabs-gcr
requires:
- hold
- docker-build:
name: proofs-tools-docker-release
filters:
tags:
only: /^proofs-tools\/v.*/
branches:
ignore: /.*/
docker_name: proofs-tools
docker_tags: <<pipeline.git.revision>>,latest
publish: true
release: true
resource_class: xlarge
context:
- oplabs-gcr
requires:
- hold
- docker-build:
name: ci-builder-rust-docker-release
filters:
Expand Down
13 changes: 13 additions & 0 deletions docker-bake.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,19 @@ target "cannon" {
tags = [for tag in split(",", IMAGE_TAGS) : "${REGISTRY}/${REPOSITORY}/cannon:${tag}"]
}

target "proofs-tools" {
dockerfile = "./ops/docker/proofs-tools/Dockerfile"
context = "."
args = {
CHALLENGER_VERSION="v1.1.0"
KONA_VERSION="kona-client-v0.1.0-alpha.3"
ASTERISC_VERSION="v1.0.2"
}
target="proofs-tools"
platforms = split(",", PLATFORMS)
tags = [for tag in split(",", IMAGE_TAGS) : "${REGISTRY}/${REPOSITORY}/proofs-tools:${tag}"]
}

target "ci-builder" {
dockerfile = "./ops/docker/ci-builder/Dockerfile"
context = "."
Expand Down
26 changes: 26 additions & 0 deletions ops/docker/proofs-tools/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
ARG GIT_COMMIT
ARG GIT_DATE

ARG CHALLENGER_VERSION
ARG KONA_VERSION
ARG ASTERISC_VERSION

FROM --platform=$BUILDPLATFORM us-docker.pkg.dev/oplabs-tools-artifacts/images/op-challenger:$CHALLENGER_VERSION AS challenger
FROM --platform=$BUILDPLATFORM ghcr.io/anton-rs/kona/kona-fpp-asterisc:$KONA_VERSION AS kona
FROM --platform=$BUILDPLATFORM ghcr.io/ethereum-optimism/asterisc/asterisc:$ASTERISC_VERSION AS asterisc

FROM --platform=$BUILDPLATFORM ubuntu:22.04 AS proofs-tools
RUN apt-get update && apt-get install -y --no-install-recommends musl
COPY --from=challenger /usr/local/bin/op-challenger /usr/local/bin/
COPY --from=challenger /usr/local/bin/cannon /usr/local/bin/
ENV OP_CHALLENGER_CANNON_BIN /usr/local/bin/cannon
COPY --from=challenger /usr/local/bin/op-program /usr/local/bin/
ENV OP_CHALLENGER_CANNON_SERVER=/usr/local/bin/op-program

COPY --from=kona /kona-host /usr/local/bin/
ENV OP_CHALLENGER_ASTERISC_KONA_SERVER=/usr/local/bin/kona-host

COPY --from=asterisc /usr/local/bin/asterisc /usr/local/bin/
ENV OP_CHALLENGER_ASTERISC_BIN=/usr/local/bin/asterisc

CMD /usr/local/bin/op-challenger
ajsutton marked this conversation as resolved.
Show resolved Hide resolved
8 changes: 8 additions & 0 deletions ops/docker/proofs-tools/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
## Proofs Tools

The proofs-tools docker image provides a collection of useful fault proofs related tools in a single docker image.
In particular it provides op-challenger with cannon, asterisc, op-program and kona-host ready to participate in
cannon, asterisc or asterisc-kona game types.

The version of each tool used in the image is specified
in [docker-bake.hcl](https://github.com/ethereum-optimism/optimism/blob/develop/docker-bake.hcl).