lambda_ethereum_consensus icon indicating copy to clipboard operation
lambda_ethereum_consensus copied to clipboard

[Infra] Create local testnet

Open Arkenan opened this issue 2 years ago • 3 comments

We should have a docker-compose that allows us to have a local testnet, with an already working full node (e.g. prysm+geth) and a testing full node (e.g. lambda ethereum consensus + reth), with an empty blockchain. This would allow us to quickly test gossiping, propagation of blocks, and others in a controlled manner, and with low resources (i.e. we won't need to save the 2TB full mainnet blockchain locally). While this is not a full-proof method, it allows us to iterate quickly and is perfectly valid to test integrations.

Arkenan avatar Sep 07 '23 09:09 Arkenan

We can modify these scripts from lighthouse to run our nodes instead. Some things to consider:

  • we'll need to add some new flags to our implementation (mainly set port in P2P/HTTP and import initial data from some dir)
  • they require installing some external tools (lighthouse, geth, and GNU grep+sed when on mac)

MegaRedHand avatar Feb 23 '24 18:02 MegaRedHand

Expanding on this, we'd need to add the following functionality:

  • import a genesis state (which corresponds to phase0) and update it to the latest spec
  • flags to set all ports (P2P, discovery, Beacon API)
  • load a custom config from a yaml

MegaRedHand avatar Feb 23 '24 20:02 MegaRedHand

@Arkenan, If I understand this issues correctly, Kurtosis is used today to accomplish this. This issue doesn't refer to smoketests but manual test right? This is tracked in #812 as:

  • Add scripts and instructions for setting up/tearing down a local testnet

Which have been added as make task alongside documentation in #1197

rodrigo-o avatar Aug 19 '24 20:08 rodrigo-o

Solved by #1197

rodrigo-o avatar Aug 27 '24 16:08 rodrigo-o