The following development environments are known to be compatible with
opendexdand are recommended for developers that are unsure what tools to use.
Consider using the following plugins for working with
Adding the two files from this gist into a
.vscodefolder within the folder where you've cloned
opendexdwill automatically provide debug configurations and general settings that are helpful when developing
Auto restart on every file change under
nodemon --watch dist -e js bin/opendexd
With some sample args disabling lndbtc/lndltc:
nodemon --watch dist -e js bin/opendexd --lndbtc.disable=true --lndltc.disable=true
We recommend to connect the
opendexdinstance you are developing on to testnet. Combined with above restarting mechanism, this lets you instantly see how your changes behave in a real-world trading environment.
- 2.Once the environment is up and running, exit from the cli session by typing
exitor open a second terminal.
- 3.Stop the opendexd container with
docker stop testnet_opendexd_1.
- 4.Copy the testnet lndbtc & lndltc folders into some path that you can easily access. E.g. into your home directory:sudo cp -R ~/.opendex-docker/testnet/data/lndbtc ~/sudo cp -R ~/.opendex-docker/testnet/data/lndltc ~/
- 5.Ensure that you own the copied folders:sudo chown -R <youruser> ~/lndbtcsudo chown -R <youruser> ~/lndltc
~/.opendexdto contain the following:[lnd.BTC]cltvdelta = 40disable = falsehost = "localhost"nomacaroons = falseport = 20009certpath = "/home/<youruser>/lndbtc/tls.cert"macaroonpath = "/home/<youruser>/lndbtc/data/chain/bitcoin/testnet/admin.macaroon"[lnd.LTC]cltvdelta = 576disable = falsehost = "localhost"nomacaroons = falseport = 21009certpath = "/home/<youruser>/lndltc/tls.cert"macaroonpath = "/home/<youruser>/lndltc/data/chain/litecoin/testnet/admin.macaroon"[connext]disable = falsehost = "localhost"port = 18000
- 7.Now you can start your local
opendexdinstance and it should connect to the running testnet docker environment. You can check that everything works with
~/opendexd/bin$ ./opendex-cli -p 18886 getinfo.