Skip to content

Commit

Permalink
mev-relay
Browse files Browse the repository at this point in the history
  • Loading branch information
lyfsn committed May 28, 2024
1 parent 8223fcb commit fcc7b00
Show file tree
Hide file tree
Showing 11 changed files with 177 additions and 12 deletions.
6 changes: 0 additions & 6 deletions docs/about-mev/intro.md

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"label": "MEV",
"position": 500,
"position": 600,
"link": {
"type": "generated-index",
}
Expand Down
15 changes: 15 additions & 0 deletions docs/mev-docs/builder.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
sidebar_position: 120
---

# MEV Builder

This is an example:

```yaml title="docker-compose.yml"

```

```bash title="start.sh"

```
11 changes: 11 additions & 0 deletions docs/mev-docs/intro.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
sidebar_position: 100
---

# MEV Intro

Endurance uses the same technology as Ethereum, so Endurance also supports MEV running. You can utilize MEV to implement functions such as MEV Protected RPC.

You can deploy a fully functional MEV infrastructure based on Flashbots:

- https://github.com/flashbots
120 changes: 120 additions & 0 deletions docs/mev-docs/relay.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,120 @@
---
sidebar_position: 110
---

# MEV Relay

This is an example:

```yaml title="docker-compose.yml"
version: '3.8'

services:
redis:
image: redis
restart: always
ports:
- '6379:6379'

memcached:
image: memcached
restart: always
ports:
- '11211:11211'

db:
image: postgres
restart: always
volumes:
- './postgres-data:/var/lib/postgresql/data'
ports:
- '5432:5432'
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: passwordpasswordpassword
POSTGRES_DB: postgres

housekeeper:
image: flashbots/mev-boost-relay:sha-634cce7
environment:
GENESIS_FORK_VERSION: "0x10000001"
GENESIS_VALIDATORS_ROOT: "0x9143aa7c615a7f7115e2b6aac319c03529df8242ae705fba9df39b79c59fa8b1"
BELLATRIX_FORK_VERSION: "0x30000001"
CAPELLA_FORK_VERSION: "0x40000001"
DENEB_FORK_VERSION: "0x50000001"
command:
housekeeper
--network custom
--db postgres://postgres:passwordpasswordpassword@db:5432/postgres?sslmode=disable
--beacon-uris ${BEACON_URL}
--redis-uri redis:6379
depends_on:
- redis
- memcached
- db

api:
image: flashbots/mev-boost-relay:sha-634cce7
environment:
GENESIS_FORK_VERSION: "0x10000001"
GENESIS_VALIDATORS_ROOT: "0x9143aa7c615a7f7115e2b6aac319c03529df8242ae705fba9df39b79c59fa8b1"
BELLATRIX_FORK_VERSION: "0x30000001"
CAPELLA_FORK_VERSION: "0x40000001"
DENEB_FORK_VERSION: "0x50000001"
ports:
- "9062:9062"
command:
api
--network custom
--secret-key 0x607a11b45a7219cc61a3d9c5fd08c7eebd602a6a19a977f8d3771d5711a550f2
--db postgres://postgres:passwordpasswordpassword@db:5432/postgres?sslmode=disable
--beacon-uris ${BEACON_URL}
--blocksim ${EXECUTION_URL}
--listen-addr 0.0.0.0:9062
--redis-uri redis:6379
--memcached-uris memcached:11211
depends_on:
- redis
- memcached
- db

website:
image: flashbots/mev-boost-relay:sha-634cce7
environment:
GENESIS_FORK_VERSION: "0x10000001"
GENESIS_VALIDATORS_ROOT: "0x9143aa7c615a7f7115e2b6aac319c03529df8242ae705fba9df39b79c59fa8b1"
BELLATRIX_FORK_VERSION: "0x30000001"
CAPELLA_FORK_VERSION: "0x40000001"
DENEB_FORK_VERSION: "0x50000001"
ports:
- "9060:9060"
command:
website
--network custom
--db postgres://postgres:passwordpasswordpassword@db:5432/postgres?sslmode=disable
--listen-addr 0.0.0.0:9060
--redis-uri redis:6379
--link-beaconchain https://beacon.fusionist.io/
--link-data-api /
--link-etherscan https://explorer-endurance.fusionist.io/
depends_on:
- redis
- memcached
- db
```
```bash title="start.sh"
export IP_ADDRESS=$(curl -4 ifconfig.io)

if [ -z "$IP_ADDRESS" ]; then
echo "Failed to retrieve IP address"
exit 1
fi

echo "Using IP address: $IP_ADDRESS"

export BEACON_URL=http://<beacon-node-ip>:5052
export EXECUTION_URL=http://<execution-node-ip>:8545

docker compose up -d
```
7 changes: 7 additions & 0 deletions docs/node-template/_category_.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"label": "Node Template",
"position": 300,
"link": {
"type": "generated-index",
}
}
8 changes: 8 additions & 0 deletions docs/node-template/reth-lighthouse.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
sidebar_position: 100
---

# Reth-Lighthouse

- https://github.com/lyfsn/mainnet-reth-lighthouse

2 changes: 1 addition & 1 deletion docs/option/_category_.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"label": "Option",
"position": 300,
"position": 500,
"link": {
"type": "generated-index",
}
Expand Down
14 changes: 12 additions & 2 deletions docs/staking-more.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,13 @@ Validator Status: {"data":[{"enabled":true,"description":"","voting_pubkey":"0xb
---
```

## Error Fix
### Error Fix

You can check your validator logs using this command:

```
docker logs -f mainnet-reth-lighthouse-validator-1
```

If you accidentally start your node before generating the secrets file, and an error appears like this:

Expand Down Expand Up @@ -102,4 +108,8 @@ Just need to execution this commond to delete the `validator_definitions.yml` fi

```
rm validator_keys/validator_definitions.yml
```
```

## Send Deposit

As in the [Send Deposit](./send-deposit.md) step, you need to send your newly generated `deposit_data-` file in the [staking launchpad](https://staking.fusionist.io/en/).
2 changes: 1 addition & 1 deletion docs/startup-paramater/network-config.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
sidebar_position: 10
---

# Nethwork config
# Nethwork Config

All network config info to run a node on Endurance is in this repo:

Expand Down
2 changes: 1 addition & 1 deletion docs/withdraw-ethdo.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
sidebar_position: 80
---

# Withdrawing Using ethdo
# Withdraw Deposit

## Base Usage

Expand Down

0 comments on commit fcc7b00

Please sign in to comment.