Skip to content

Commit 3e81771

Browse files
authored
fix: remove datadir before devnet run (lambdaclass#379)
## 🗒️ Description / Motivation Running `make run-devnet` more than once results in errors due to another database already existing. This can be solved by deleting the whole datadir after a devnet run. ## What Changed A step deleting `lean-quickstart/local-devnet/data/` was added to the `run-devnet` make target.
1 parent a854b5e commit 3e81771

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

Makefile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@ lean-quickstart:
3838
git clone https://github.com/blockblaz/lean-quickstart.git --depth 1 --single-branch
3939

4040
run-devnet: docker-build lean-quickstart ## 🚀 Run a local devnet using lean-quickstart
41+
@# Remove local devnet data folder to avoid stale data
42+
@# NOTE: --cleanData flag in spin-node.sh doesn't work
43+
@rm -rf lean-quickstart/local-devnet/data/
4144
@echo "Starting local devnet with ethlambda client (\"$(DOCKER_TAG)\" tag). Logs will be dumped in devnet.log, and metrics served in http://localhost:3000"
4245
@echo
4346
@echo "Devnet will be using the current configuration. For custom configurations, modify lean-quickstart/local-devnet/genesis/validator-config.yaml and restart the devnet."

0 commit comments

Comments
 (0)