web3-proxy/Dockerfile

22 lines
626 B
Docker
Raw Normal View History

2022-05-12 22:58:26 +03:00
FROM rust:1-bullseye as builder
2022-04-23 21:00:03 +03:00
2022-12-15 06:25:57 +03:00
ENV PATH /root/.foundry/bin:$PATH
RUN curl -L https://foundry.paradigm.xyz | bash && foundryup
2022-08-06 08:46:33 +03:00
WORKDIR /usr/src/web3_proxy
2022-04-23 21:00:03 +03:00
COPY . .
RUN --mount=type=cache,target=/usr/local/cargo/registry \
2022-08-06 08:46:33 +03:00
--mount=type=cache,target=/usr/src/web3_proxy/target \
2022-12-15 06:02:49 +03:00
cargo test &&\
cargo install --locked --no-default-features --root /opt/bin --path ./web3_proxy
2022-04-23 21:00:03 +03:00
2022-05-12 22:58:26 +03:00
FROM debian:bullseye-slim
2022-05-06 04:25:49 +03:00
2022-12-22 22:49:34 +03:00
COPY --from=builder /opt/bin/* /usr/local/bin/
2023-01-18 08:26:10 +03:00
ENTRYPOINT ["web3_proxy_cli"]
2023-01-19 13:32:24 +03:00
CMD [ "--config", "/web3-proxy.toml", "proxyd" ]
2022-05-12 22:58:26 +03:00
# TODO: lower log level when done with prototyping
ENV RUST_LOG "web3_proxy=debug"