@@ -26,6 +26,7 @@ ARG OP_PROGRAM_VERSION=v0.0.0
2626
2727ARG TARGETOS TARGETARCH
2828
29+ # Build the cannon, op-program, and op-program-client.elf binaries.
2930RUN --mount=type=cache,target=/root/.cache/go-build cd cannon && make cannon \
3031 GOOS=$TARGETOS GOARCH=$TARGETARCH GITCOMMIT=$GIT_COMMIT GITDATE=$GIT_DATE VERSION="$CANNON_VERSION"
3132RUN --mount=type=cache,target=/root/.cache/go-build cd op-program && make op-program-host \
@@ -36,13 +37,12 @@ RUN --mount=type=cache,target=/root/.cache/go-build cd op-program && make op-pro
3637# Run the op-program-client.elf binary directly through cannon's load-elf subcommand.
3738RUN /app/cannon/bin/cannon load-elf --path /app/op-program/bin/op-program-client.elf --out /app/op-program/bin/prestate.json --meta ""
3839
39- # Generate the prestate proof.
40+ # Generate the prestate proof containing the absolute pre-state hash .
4041RUN /app/cannon/bin/cannon run --proof-at '=0' --stop-at '=1' --input /app/op-program/bin/prestate.json --meta "" --proof-fmt '/app/op-program/bin/%d.json' --output ""
4142RUN mv /app/op-program/bin/0.json /app/op-program/bin/prestate-proof.json
4243
43- # Export the prestate.json file to the specified output location.
44- # The output location can be overridden by setting the target's output.
45- # Additionally, writing files to host requires buildkit to be enabled.
44+ # Exports files to the specified output location.
45+ # Writing files to host requires buildkit to be enabled.
4646# e.g. `BUILDKIT=1 docker build ...`
4747FROM scratch AS export-stage
4848COPY --from=builder /app/op-program/bin/op-program .
0 commit comments