3️⃣Deploy Backend

Backend App

LN-STX Bridge has very few requirements and can be installed by running below commands as detailed in the github repository readme.

// ensure you have node-14 installed

// clone the repo, install requirements and compile
git clone https://github.com/pseudozach/lnstxbridge.git
cd lnstxbridge && npm i && npm run compile

Contracts

Each bridge instance should run its own swap contracts for both transparency purposes and to make it easy for the bridge backend to track the swaps.

Easiest way to deploy the swap contracts is to launch explorer sandbox, copy/paste contents of the latest version of the contracts and click deploy!

Signer Account

As a swap provider, lnstxbridge will need access to private keys for a stacks account that has STX (and any other SIP10 you plan to serve).

Generate a new stacks account using any available method (hiro wallet or stx cli) send STX funds into this account and place the mnemonic seed of this account on the server at ~/.lnstx/seed.dat

Configuration

Once the app is ready and contracts are deployed, it's time to build the configuration file that feeds this data to the app.

Data in this file is mostly personal choice and depend on operator's environment. Feel free to join #developers channel in our discord and ask if anything is unclear.

Ready to Launch!

Now that you've prepared all the requirements you can deploy your backend!

Last updated