Skip to content

Conversation

@Othryades
Copy link
Collaborator

@Othryades Othryades commented Dec 15, 2025

This PR implements issue(s) #

Checklist

  • I wrote new tests for my new core changes.
  • I have successfully ran tests, style checker and build against my new changes locally.
  • I have informed the team of any breaking changes if there are any.

Note

Use a patched Erigon v3.3.0 image for Linea Mainnet/Sepolia with Engine API/JWT settings for Maru, and add a Dockerfile to build the patched image.

  • Docs/Configs:
    • Erigon (Linea Mainnet & Sepolia):
      • Replace erigontech/erigon:2.61.0 with morislineats/erigon:v3.3.0-linea-patched and set pull_policy: always.
      • Rework init to "erigon init --datadir=/data /genesis.json" with entrypoint /bin/sh -c; update volumes to ./geth/geth-genesis.json and map data to /data.
      • Update node args: add --datadir=/data, --externalcl, --prune.mode=full, --nat=extip:${EXTERNAL_IP:-0.0.0.0}; refresh --bootnodes (mainnet) and keep sepolia list.
      • Enable Engine API for Maru: add --authrpc.* flags, mount JWT at /data/jwt, expose/map port 8550.
      • Add hostname/container_name for erigon-node.
    • New file: docs/getting-started/linea-mainnet/erigon-linea/Dockerfile
      • Builds Erigon v3.3.0 with Linea-specific patches and nosilkworm, producing a minimal runtime image.

Written by Cursor Bugbot for commit e88e6d9. This will update automatically on new commits. Configure here.

Othryades and others added 14 commits December 8, 2025 17:42
- Use morislineats/erigon:v3.3.0-linea-patched image
- Includes Keith C's fixes for fresh sync:
  - sentryMcDisableBlockDownload = false
  - Return nil for EIP-7002/7251 empty code
- prune.mode=full for standard sync
- Comment for future v3.4.0 upgrade
- Use morislineats/erigon:v3.3.0-linea-patched image
- Add --externalcl for Maru CL integration
- Add Engine API config (authrpc on port 8550)
- Update prune flag to --prune.mode=full (v3.x syntax)
- Fix datadir and volume paths
- Comment for future v3.4.0 upgrade
RUN git clone --depth 1 --branch v3.3.0 https://github.com/erigontech/erigon.git .

# Patch 1: Disable block downloader v2 (fixes corruption on EC2/slower machines)
RUN sed -i 's/const sentryMcDisableBlockDownload = true/const sentryMcDisableBlockDownload = false/' node/eth/backend.go
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: Patch comment contradicts actual code change behavior

The comment on line 16 says "Disable block downloader v2" but the sed command on line 17 changes sentryMcDisableBlockDownload from true to false. Since sentryMcDisableBlockDownload = true means the block downloader is disabled, setting it to false actually ENABLES the block downloader. This is the opposite of what the comment describes. If the goal is to disable the block downloader to prevent corruption on EC2/slower machines, the patch is doing the wrong thing.

Fix in Cursor Fix in Web

erigon-node:
image: erigontech/erigon:2.61.0
hostname: el-client
container_name: linea-erigon
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: Same container name used for both networks

Both the mainnet and sepolia docker-compose files set container_name: linea-erigon for the Erigon node. Docker requires globally unique container names within a daemon. If a user attempts to run both mainnet and sepolia configurations simultaneously (even from different directories), Docker will fail with a container name conflict error. The container names need to be distinct (e.g., linea-erigon-mainnet and linea-erigon-sepolia).

Additional Locations (1)

Fix in Cursor Fix in Web

# Erigon v3.3.0 patched for Linea
# Based on Keith C's findings: https://github.com/erigontech/erigon/issues/18160

FROM golang:1.24-bookworm AS builder
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why keep a Dockerfile if you rely on an externally built Docker image?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants