-
Notifications
You must be signed in to change notification settings - Fork 800
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Information for network testing (#4961)
* Documentation for network testing * Update doc
- Loading branch information
1 parent
c55608b
commit a7e5926
Showing
1 changed file
with
74 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
# Lighthouse live network testing | ||
|
||
|
||
## DISCLAIMER | ||
|
||
This document describes how to run a lighthouse node with minimal resources and time on a live | ||
network. | ||
|
||
This procedure should ONLY be used for testing networks and never in production and never with | ||
attached validators. The Lighthouse node described in this state is only a partially functioning | ||
node. | ||
|
||
|
||
## Overview | ||
|
||
We are going to run a single lighthouse node connected to a live network, without syncing and | ||
without an execution engine. This should only ever be done for testing. | ||
|
||
There two main components needed. | ||
|
||
1. A lighthouse node that doesn't sync | ||
2. A fake execution client that does nothing | ||
|
||
We will start with the second | ||
|
||
## Mock-EL | ||
|
||
This is a service that runs and fakes an execution engine. We firstly need to install the lighthouse | ||
`lcli` tool. | ||
|
||
``` | ||
$ make install-lcli | ||
``` | ||
|
||
Once installed, run the fake execution client: | ||
|
||
``` | ||
$ lcli mock-el --jwt-output-path /tmp/mockel.jwt | ||
``` | ||
|
||
This will create a server listening on localhost:8551 | ||
|
||
## Lighthouse no sync | ||
|
||
To create a lighthouse node that doesn't sync we need to compile it with a special flag. | ||
|
||
``` | ||
$ cargo build --release --bin lighthouse --features network/disable-backfill | ||
``` | ||
|
||
Once built, it can run via checkpoint sync on any network, making sure we point to our mock-el | ||
|
||
Prater testnet: | ||
|
||
``` | ||
$ lighthouse --network prater bn --execution-jwt /tmp/mockel.jwt --checkpoint-sync-url | ||
https://prater.checkpoint.sigp.io --execution-endpoint http://localhost:8551 | ||
``` | ||
|
||
Mainnet: | ||
|
||
``` | ||
$ lighthouse --network prater bn --execution-jwt /tmp/mockel.jwt --checkpoint-sync-url | ||
https://checkpoint.sigp.io --execution-endpoint http://localhost:8551 | ||
``` | ||
|
||
Additional flags, such as metrics may be added. | ||
|
||
|
||
## Additional Notes | ||
|
||
The above is assuming that you have not run the command in the past. If you have a database in | ||
existence for the network you are testing, checkpoint sync will not start. You may need to add the | ||
`--purge-db` flag to remove any past database and force checkpoint sync to run. |