To use Xena Exchange dAccs, you have to deploy a Lightning node (forked by Xena Exchange) to your server. We recommend running the node in a docker container, although this is not mandatory.
Install pritunl (a VPN client): official documentation, all platforms
The support team will respond with a link that must be passed to the pritunl client to set up the connection
The node is needed by the Lightning node just to observe the blockchain. It does not need to store the private keys of any wallets.
Note that the node will download the whole blockchain (> 200 Gb of data as of now, may take up to a week to download and sync before becoming operational)
Prepare a local directory that will be used as the data directory for the Lightning node (the keys of your Lightning wallet will be stored here, along with other information)
It’s advised to ensure the directory is backed up on a regular basis
If you have an existing backup, copy it into this directory. In this example, we will use “/local/mount/path”
Build a docker image or use an existing one https://hub.docker.com/r/xenaexchange/lnd
Set up and run the Xena Exchange Lightning node in the docker
CLI binaries for different platforms can be downloaded here: https://github.com/xenaex/daccs-cli/releases
Building the docker container on the local machine
Proceed to https://github.com/xenaex/lnd (the repository containing Xena Exchange’s Lightning fork)
Download the docker file and the docker-entrypoint.sh and build the docker container with yours Github credentials.
docker build --build-arg USER=<login> --build-arg PASS=<password> -t xenaexchange/lnd </path/with/downloaded_dockerfile_and_docker-entrypoint>
Running the node
# docker run arguments:
*for MacOS use the command "-it -v /var:/blockchain \" for the directory settings.
After running, the container will create the “/local/mount/path/data/chain/bitcoin/mainnet/admin.macaroon” and “/local/mount/path/data/tls.cer” files. When using the Xena Exchange dAccs CLI, pass the paths to these files to the --lnd-macaroon and --lnd-tls-cert arguments.
Creating a new Lightning wallet
Use the Lightning CLI command to create a new wallet. Provided that your Lightning node is running in the docker container named “lightning-client-node” and the node is configured to use the mainnet network, execute the following command:
docker exec -it lightning-client-node lncli --network=mainnet --lnddir=/blockchain create
Importing a VPN profile using the pritunl UI client
Copy the link you have received from support and past it in the “Import Profile URI” dialog box:
Go to the menu and click “Connect”:
If the connection has been established successfully, you will see the time on the “online for” counter increasing.