Skip to content

Commit

Permalink
Remove databases at start.
Browse files Browse the repository at this point in the history
  • Loading branch information
nalepae committed Jan 8, 2024
1 parent 4f4c28e commit 10ee564
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,14 @@ services:
- ./consensus:/consensus
- ./execution:/execution

# Removes the database of the go-ethereum execution client to ensure we start from a clean state.
# (geth has a `removedb` option, but it asks for a keyboard confirmation, so we use this instead)
geth-remove-db:
image: "alpine:3.19.0"
command: rm -rf /execution/geth
volumes:
- ./execution:/execution

# Sets up the genesis configuration for the go-ethereum client from a JSON file.
geth-genesis:
image: "ethereum/client-go:latest"
Expand All @@ -28,6 +36,8 @@ services:
depends_on:
create-beacon-chain-genesis:
condition: service_completed_successfully
geth-remove-db:
condition: service_completed_successfully

# Runs a Prysm beacon chain from a specified genesis state created in the previous step
# and connects to go-ethereum in the same network as the execution client.
Expand Down Expand Up @@ -55,6 +65,7 @@ services:
- --suggested-fee-recipient=0x123463a4b065722e99115d6c222f267d9cabb524
- --minimum-peers-per-subnet=0
- --enable-debug-rpc-endpoints
- --force-clear-db
depends_on:
create-beacon-chain-genesis:
condition: service_completed_successfully
Expand Down Expand Up @@ -116,6 +127,7 @@ services:
- --interop-num-validators=64
- --interop-start-index=0
- --chain-config-file=/consensus/config.yml
- --force-clear-db
depends_on:
beacon-chain:
condition: service_started
Expand Down

0 comments on commit 10ee564

Please sign in to comment.