-
Notifications
You must be signed in to change notification settings - Fork 93
Expand file tree
/
Copy pathDockerfile
More file actions
33 lines (26 loc) · 967 Bytes
/
Dockerfile
File metadata and controls
33 lines (26 loc) · 967 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
FROM --platform=linux/amd64 rust:1.88.0-bookworm as builder
ENV CARGO_NET_GIT_FETCH_WITH_CLI=true
RUN curl -fsSL https://deb.nodesource.com/setup_lts.x | bash - && \
apt-get update && apt-get install -y \
pkg-config \
libssl-dev \
clang \
libclang-dev \
nodejs \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /app
COPY . .
# Build for standard Linux (glibc) instead of musl
RUN RUSTFLAGS='-C target-cpu=x86-64-v2' cargo build --release --features jemalloc,reth --workspace --exclude rindexer_rust_playground
FROM --platform=linux/amd64 debian:bookworm-slim
RUN apt-get update && apt-get install -y \
libssl3 \
ca-certificates \
curl \
git \
&& rm -rf /var/lib/apt/lists/*
RUN curl -L https://foundry.paradigm.xyz | bash
RUN /root/.foundry/bin/foundryup
COPY --from=builder /app/target/release/rindexer_cli /app/rindexer
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
ENTRYPOINT ["/app/rindexer"]