An environment for local development and testing, successor of legend-regtest-enviroment.
Docker or Orbstack for Apple Silicon based Macs.
When using OrbStack on macOS, set export DOCKER_DEFAULT_PLATFORM=linux/amd64 before starting.
./start.sh./stop.sh- Web App: http://localhost:8080
- API: http://localhost:9001
Data dirs for the services are stored in ./data folder.
docker exec -it boltz-scripts bash- bitcoin-cli-sim-client
- bitcoin-cli-sim-server
- elements-cli-sim-client
- elements-cli-sim-server
- lightning-cli-sim-client
- lightning-cli-sim-server
- lncli-sim-client
- lncli-sim-server
- boltz-client-cli-sim
- boltz-backend-cli-sim
Or alternatively, you can source aliases.sh to have these convenience scripts available on the host machine.
Esplora is running for the Bitcoin Core and Elements regtest:
- Bitcoin: http://localhost:4002
- Elements: http://localhost:4003
Otterscan is used as block explorer for Anvil: http://localhost:5100
Run ./start.sh and enter the scripts container or add aliases on your host as described above.
Check the client's bitcoin wallet balance:
bitcoin-cli-sim-client getbalanceCheck the client's LND channel balance:
lncli-sim-client channelbalanceGenerate e.g. a Bitcoin -> Lightning swap in Web App using Client's LND as destination with a 100k sats invoice:
lncli-sim-client addinvoice --amt 100000Send the required Bitcoin amount into the swap, e.g. with
bitcoin-cli-sim-client sendtoaddress bcrt1qfzjp72mft2kcx49w49l5v6vdegr7lff86j08w7 0.00104200Mine three blocks for the swap to process and watch web app progress to the swap success screen:
bitcoin-cli-sim-client -generate 3Check the client's bitcoin wallet balance again:
bitcoin-cli-sim-client getbalanceCheck the client's LND channel balance again:
lncli-sim-client channelbalance./stop.sh
docker compose pull
./start.sh