Skip to content

Commit bbcb71f

Browse files
authored
fix: improve docs (#125)
1 parent 8ec2a4e commit bbcb71f

File tree

5 files changed

+82
-20
lines changed

5 files changed

+82
-20
lines changed

docs/docs/get_started/configuration.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ description: Configure Commit-Boost
44

55
# Configuration
66

7-
After the Commit-Boost CLI and the modules are setup as detailed in the previous section, you will need to create a `cb-config.toml` file, detailing all the services that you want to run.
7+
Commit-Boost needs a configuration file detailing all the services that you want to run. Create a `cb-config.toml` and adjust it depending on which modules you plan to run.
88

99
For a full explanation of all the fields, check out [here](https://github.com/Commit-Boost/commit-boost-client/blob/main/config.example.toml).
1010

@@ -25,10 +25,12 @@ prometheus_config = "./docker/prometheus.yml"
2525
```
2626

2727
You can find a list of MEV-Boost Holesky relays [here](https://www.coincashew.com/coins/overview-eth/mev-boost/mev-relay-list#holesky-testnet-relays).
28+
After the sidecar is started, it will expose a port (`18550` in this example), that you need to point your CL to. This may be different depending on which CL you're running, check out [here](https://docs.flashbots.net/flashbots-mev-boost/getting-started/system-requirements#consensus-client-configuration-guides) for a list of configuration guides.
29+
2830
Note that in this setup, the signer module will not be started.
2931

3032
## Custom module
31-
We currently provide a test module that needs to be built as a Docker image. To build the module run:
33+
We currently provide a test module that needs to be built locally. To build the module run:
3234
```bash
3335
bash scripts/build_local_modules.sh
3436
```

docs/docs/get_started/overview.md

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -8,19 +8,18 @@ description: Initial setup
88
Commit-Boost is currently in alpha development and **NOT** ready for production use. Please use caution
99
:::
1010

11+
Commit-Boost is primarily based on [Docker](https://www.docker.com/) to enable modularity, sandboxing and cross-platform compatibility. It is also possible to run Commit-Boost [natively](/get_started/running/binary) without Docker.
1112

12-
Commit-Boost currently uses [Docker](https://www.docker.com/) to enable modularity, sandboxing and cross-platform compatibility. We're also exploring [alternative](https://github.com/Commit-Boost/commit-boost-client/issues/18) approaches.
13-
14-
In the current setup, each component roughly maps to a container: from a single `.toml` config file, the node operator can specify which modules they want to run, and Commit-Boost takes care of spinning up the services and creating links between them.
13+
Each component roughly maps to a container: from a single `.toml` config file, the node operator can specify which modules they want to run, and Commit-Boost takes care of spinning up the services and creating links between them.
1514
Commit-Boost ships with two core modules:
1615
- a PBS module which implements implements the [BuilderAPI](https://ethereum.github.io/builder-specs/) for [MEV Boost](https://docs.flashbots.net/flashbots-mev-boost/architecture-overview/specifications)
1716
- a signer module, which implements the [Signer API](/api) and provides the interface for modules to request proposer commitments
1817

1918
## Setup
2019

21-
The Commit-Boost CLI creates a dynamic `docker-compose` file, with services and ports already set up. Alternatively, you can also run each module natively without using Docker.
20+
The Commit-Boost CLI creates a dynamic `docker-compose` file, with services and ports already set up.
2221

23-
Either way, you can compile from source from our repo, or download binaries and fetch docker images from the official releases.
22+
Whether you're using Docker or running the binaries natively, you can compile from source directly from the repo, or download binaries and fetch docker images from the official releases.
2423

2524
### Binaries and images
2625
Find the latest releases at https://github.com/Commit-Boost/commit-boost-client/releases.
@@ -44,11 +43,11 @@ git checkout stable
4443
```
4544

4645
:::note
47-
If you get an `openssl` related error try running: `apt-get update && apt-get install -y openssl ca-certificates libssl3 libssl-dev`
46+
If you get an `openssl` related error try running: `apt-get update && apt-get install -y openssl ca-certificates libssl3 libssl-dev build-essential pkg-config`
4847
:::
4948

5049
#### Docker
51-
You can now build the CLI:
50+
You will need to build the CLI to create the `docker-compose` file:
5251

5352
```bash
5453
# Build the CLI
@@ -71,13 +70,13 @@ This will create two local images called `commitboost_pbs_default` and `commitbo
7170

7271
#### Binaries
7372

74-
Alternatively, you can also build the modules from source and run them without Docker, in which case you wouldn't need the CLI:
73+
Alternatively, you can also build the modules from source and run them without Docker, in which case you can skip the CLI and only compile the modules:
7574

7675
```bash
77-
# Build the PBS module
76+
# Build the PBS module, this corresponds to commit-boost-pbs in the releases
7877
cargo build --release --bin default-pbs
7978

80-
# Build the Signer module
79+
# Build the Signer module, this corresponds to commit-boost-signer in the releases
8180
cargo build --release --bin signer-module
8281
```
8382

docs/docs/get_started/running/binary.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ description: Run Commit-Boost modules natively
33
---
44

55
# Binary
6-
It is also possible to run the native modules without using docker.
76

87
:::warning
98
Running the modules natively means you opt out of the security guarantees made by Docker and it's up to you how to setup and ensure the modules run safely
@@ -13,7 +12,7 @@ Running the modules natively means you opt out of the security guarantees made b
1312
## Setup
1413
Get the binary of the module either by compiling from source or by downloading a [published release](https://github.com/Commit-Boost/commit-boost-client/releases).
1514

16-
Modules need some environment variables to work correctly. Here is the complete list
15+
Modules need some environment variables to work correctly.
1716

1817
### Common
1918
- `CB_CONFIG`: required, path to the `toml` config file
@@ -45,7 +44,7 @@ Modules might also have additional envs required, which should be detailed by th
4544

4645
## Start
4746

48-
After creating the `cb-config.toml` file, you need to setup the required envs and run the binary. For example:
47+
After creating the `cb-config.toml` file, setup the required envs and run the binary. For example:
4948

5049
```bash
5150
CB_CONFIG=./cb-config.toml commit-boost-pbs

docs/docs/get_started/running/docker.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@ description: Run Commit-Boost with Docker
33
---
44

55
# Docker
6-
The `commit-boost` cli will generate a dynamic `docker-compose.yml` file using the provided `toml` config file. This is the recommended approach as Docker provides sandboxing of the containers from the rest of your system.
6+
The Commit-Boost CLI will generate a dynamic `docker-compose.yml` file using the provided `toml` config file. This is the recommended approach as Docker provides sandboxing of the containers from the rest of your system.
77

88
## Init
99

10-
After creating the `cb-config.toml` file, you can now run the Commit-Boost sidecar. First run:
10+
First run:
1111
```bash
1212
commit-boost init --config cb-config.toml
1313
```
@@ -23,11 +23,11 @@ To start Commit-Boost run:
2323
commit-boost start --docker cb.docker-compose.yml [--env .cb.env]
2424
```
2525

26-
This will start up the services including PBS, commit modules (if any), and metrics collection (if enabled).
26+
This will run `docker compose up` with the correct envs, and start up the services including PBS, commit modules (if any), and metrics collection (if enabled).
2727

2828
The MEV-Boost server will be exposed at `pbs.port` from the config, `18550` in our example. You'll need to point your CL/Validator client to this port to be able to source blocks from the builder market.
2929

30-
If enabled, this will also start a Prometheus server on port `9090` and a Grafana instance on port `3000`. In Grafana, you will also find some preset dabhboards already connected.
30+
If enabled, this will also start a Prometheus server on port `9090` and a Grafana instance on port `3000`. In Grafana, you will also find some preset dashboards already connected.
3131

3232

3333
## Logs

docs/docs/get_started/troubleshooting.md

Lines changed: 63 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,66 @@ description: Common issues
33
---
44

55
# Troubleshooting
6-
Commit-Boost is currently in alpha development so it's likely there are bugs, if you find any or have any question, please reach out on [Twitter](https://x.com/Commit_Boost) or [Telegram](https://t.me/+Pcs9bykxK3BiMzk5).
6+
7+
Commit-Boost is currently in alpha development so it's likely there are bugs, if you find any or have any question, please reach out on [Twitter](https://x.com/Commit_Boost) or [Telegram](https://t.me/+Pcs9bykxK3BiMzk5).
8+
9+
10+
If you started the modules correctly you should see the following logs.
11+
12+
## PBS
13+
After the module started correctly you should see:
14+
```bash
15+
2024-09-16T19:27:16.004643Z INFO Starting PBS service address=0.0.0.0:18550 events_subs=0
16+
```
17+
18+
To check that the setup is correct and you are connected to relays, you can trigger manually the `/status` endpoint, by running:
19+
20+
```bash
21+
curl http://0.0.0.0:18550/eth/v1/builder/status -vvv
22+
23+
* Trying 0.0.0.0:18550...
24+
* Connected to 0.0.0.0 (127.0.0.1) port 18550 (#0)
25+
> GET /eth/v1/builder/status HTTP/1.1
26+
> Host: 0.0.0.0:18550
27+
> User-Agent: curl/7.81.0
28+
> Accept: */*
29+
>
30+
* Mark bundle as not supporting multiuse
31+
< HTTP/1.1 200 OK
32+
< content-length: 0
33+
< date: Mon, 16 Sep 2024 19:32:07 GMT
34+
<
35+
* Connection #0 to host 0.0.0.0 left intact
36+
```
37+
38+
if now you check the logs, you should see:
39+
40+
```bash
41+
2024-09-16T19:32:07.634966Z INFO status{req_id=62f1c0db-f277-49fa-91e7-a9a1c2b2a6d3}: ua="curl/7.81.0" relay_check=true
42+
2024-09-16T19:32:07.642992Z INFO status{req_id=62f1c0db-f277-49fa-91e7-a9a1c2b2a6d3}: relay check successful
43+
```
44+
45+
If the sidecar is setup correctly, it will receive and process calls from the CL:
46+
#### Register validator
47+
This should happen periodically, depending on your validator setup.
48+
49+
```bash
50+
2024-09-16T19:28:37.976534Z INFO register_validators{req_id=296f662f-0e7a-4f15-be75-55b8ca19ffc0}: ua="Lighthouse/v5.2.1-9e12c21" num_registrations=500
51+
2024-09-16T19:28:38.819591Z INFO register_validators{req_id=296f662f-0e7a-4f15-be75-55b8ca19ffc0}: register validator successful
52+
```
53+
54+
#### Get header
55+
This will only happen if some of your validators have a proposal slot coming up.
56+
57+
```bash
58+
2024-09-16T19:30:24.135376Z INFO get_header{req_id=74126c5f-69e6-4961-86a6-6c2597bf15f5 slot=2551052}: ua="Lighthouse/v5.2.1-9e12c21" parent_hash=0x641c99d6e4f14bf6d268eb2a8c0dc51c7030ab24e384c0e679f2a6b438d298ea validator_pubkey=0x84fc20b09496341f24abfcb6f407e916ecc317497c5b1bba4970e50e96cf5e731b88e51753064c30cb221453bd71aebf ms_into_slot=135
59+
2024-09-16T19:30:25.089477Z INFO get_header{req_id=74126c5f-69e6-4961-86a6-6c2597bf15f5 slot=2551052}: received header block_hash=0x0139686e8d251f010153875270256fce6f298d7b3f3f9129179fb86297dffad3 value_eth="0.001399518501462470"
60+
```
61+
62+
#### Submit block
63+
This will only happen if you received a header in the previous call, and if the header is higher than the locally built block.
64+
65+
```bash
66+
2024-09-16T14:38:01.409075Z INFO submit_blinded_block{req_id=6eb9a04d-6f79-4295-823f-c054582b3599 slot=2549590}: ua="Lighthouse/v5.2.1-9e12c21" slot_uuid=16186e06-0cd0-47bc-9758-daa1b66eff5c ms_into_slot=1409 block_hash=0xfa135ae6f2bfb32b0a47368f93d69e0a2b3f8b855d917ec61d78e78779edaae6
67+
2024-09-16T14:38:02.910974Z INFO submit_blinded_block{req_id=6eb9a04d-6f79-4295-823f-c054582b3599 slot=2549590}: received unblinded block
68+
```

0 commit comments

Comments
 (0)