This commit is contained in:
2026-06-07 09:12:43 +02:00
parent eeb894d783
commit 241c52848b
3 changed files with 13 additions and 5 deletions

View File

@@ -293,7 +293,7 @@ RUN --mount=type=cache,target=/usr/local/cargo/registry \
fi
# Final stage - minimal runtime
FROM debian:trixie-slim
FROM debian:trixie-slim AS runtime-common
# Install runtime dependencies including jemalloc for better memory performance
RUN apt-get update && apt-get install -y \
@@ -315,13 +315,17 @@ RUN useradd -m -u 1000 -s /bin/bash reth
RUN mkdir -p /root/.local/share/reth && \
chown -R reth:reth /root/.local/share
# Use jemalloc for better memory performance
ENV LD_PRELOAD=/usr/lib/x86_64-linux-gnu/libjemalloc.so.2
ENV MALLOC_CONF="background_thread:true,metadata_thp:auto,dirty_decay_ms:30000,muzzy_decay_ms:30000"
USER reth
EXPOSE 30303 30303/udp 9001 8545 8546
# Dynamic entrypoint based on build type
ENTRYPOINT ["/usr/local/bin/reth"]
ENTRYPOINT ["/usr/local/bin/reth"]
# Default: preload system jemalloc for binaries built without a bundled allocator
FROM runtime-common AS runtime
ENV LD_PRELOAD=/usr/lib/x86_64-linux-gnu/libjemalloc.so.2
# alethia-reth links jemalloc statically; LD_PRELOAD causes SIGSEGV at startup
FROM runtime-common AS runtime-alethia

View File

@@ -46,6 +46,7 @@ services:
build:
context: ./
dockerfile: reth.Dockerfile
target: runtime-alethia
args:
LLVM_IMAGE: ${LLVM_IMAGE:-snowstep/llvm}
LLVM_VERSION: ${LLVM_VERSION:-20250912105042}
@@ -79,6 +80,7 @@ services:
env_file:
- ./taiko/alethia.env
environment:
- LD_PRELOAD=
- BOOTNODES=enode://266a8e3b5e44201eca9c368d58aa59a7750295397e77d5b32aea2644f9962cbc4e1cb0543aab0480995a209408174413f65e5ce253d60bb83d22d3b8ab12eb89@34.142.239.251:30303,enode://264a7fc4bd1ee16cfc6eb420c643407bfc61b9c9534c5a39ba6e68c8759beda2fbeccefee8677385e3d99691eeb218da4bce7f5207cf38594ac0f6a53c128b9b@35.247.159.156:30303,enode://2d4e5b7ec0c57f9def6ebe72f9bd1f65c33c87b7dc38875bbb147c10e8ec9a8cd157558b695f9a02ac6ad789f300fab4f1f19d41273956491372e96880a3459f@34.126.90.255:30303,enode://57f4b29cd8b59dc8db74be51eedc6425df2a6265fad680c843be113232bbe632933541678783c2a5759d65eac2e2241c45a34e1c36254bccfe7f72e52707e561@104.197.107.1:30303,enode://87a68eef46cc1fe862becef1185ac969dfbcc050d9304f6be21599bfdcb45a0eb9235d3742776bc4528ac3ab631eba6816e9b47f6ee7a78cc5fcaeb10cd32574@35.232.246.122:30303
entrypoint: [reth, node]
command:

View File

@@ -46,6 +46,7 @@ services:
build:
context: ./
dockerfile: reth.Dockerfile
target: runtime-alethia
args:
LLVM_IMAGE: ${LLVM_IMAGE:-snowstep/llvm}
LLVM_VERSION: ${LLVM_VERSION:-20250912105042}
@@ -79,6 +80,7 @@ services:
env_file:
- ./taiko/alethia.env
environment:
- LD_PRELOAD=
- BOOTNODES=enode://266a8e3b5e44201eca9c368d58aa59a7750295397e77d5b32aea2644f9962cbc4e1cb0543aab0480995a209408174413f65e5ce253d60bb83d22d3b8ab12eb89@34.142.239.251:30303,enode://264a7fc4bd1ee16cfc6eb420c643407bfc61b9c9534c5a39ba6e68c8759beda2fbeccefee8677385e3d99691eeb218da4bce7f5207cf38594ac0f6a53c128b9b@35.247.159.156:30303,enode://2d4e5b7ec0c57f9def6ebe72f9bd1f65c33c87b7dc38875bbb147c10e8ec9a8cd157558b695f9a02ac6ad789f300fab4f1f19d41273956491372e96880a3459f@34.126.90.255:30303,enode://57f4b29cd8b59dc8db74be51eedc6425df2a6265fad680c843be113232bbe632933541678783c2a5759d65eac2e2241c45a34e1c36254bccfe7f72e52707e561@104.197.107.1:30303,enode://87a68eef46cc1fe862becef1185ac969dfbcc050d9304f6be21599bfdcb45a0eb9235d3742776bc4528ac3ab631eba6816e9b47f6ee7a78cc5fcaeb10cd32574@35.232.246.122:30303
entrypoint: [reth, node]
command: