FROM golang:1.22 AS op WORKDIR /app ENV REPO=https://github.com/ethereum-optimism/optimism.git ENV VERSION=v1.9.5 ENV COMMIT=5662448279e4fb16e073e00baeb6e458b12a59b2 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 VERSION=$VERSION op-node FROM rust:1.82 AS reth ARG FEATURES=jemalloc,asm-keccak,optimism WORKDIR /app RUN apt-get update && apt-get -y upgrade && apt-get install -y git libclang-dev pkg-config curl build-essential ENV REPO=https://github.com/paradigmxyz/reth.git ENV VERSION=v1.1.1 ENV COMMIT=15c230bac20e2b1b3532c8b0d470e815fbc0cc22 RUN git clone $REPO --branch $VERSION --single-branch . && \ git switch -c branch-$VERSION && \ bash -c '[ "$(git rev-parse HEAD)" = "$COMMIT" ]' RUN cargo build --bin op-reth --features $FEATURES --profile maxperf --manifest-path crates/optimism/bin/Cargo.toml FROM ubuntu:22.04 RUN apt-get update && \ apt-get install -y jq curl supervisor && \ rm -rf /var/lib/apt/lists RUN mkdir -p /var/log/supervisor WORKDIR /app COPY --from=op /app/op-node/bin/op-node ./ COPY --from=reth /app/target/maxperf/op-reth ./ COPY supervisord.conf /etc/supervisor/conf.d/supervisord.conf COPY ./reth/reth-entrypoint ./execution-entrypoint COPY op-node-entrypoint . CMD ["/usr/bin/supervisord"]