From 43382a322b19db7bf6ab2c695655dcb7e4085e66 Mon Sep 17 00:00:00 2001 From: Botrel Kilian Date: Thu, 4 Nov 2021 17:16:24 +0100 Subject: [PATCH] chore: update link --- README.md | 2 +- dev/README.md | 77 +++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 78 insertions(+), 1 deletion(-) create mode 100644 dev/README.md diff --git a/README.md b/README.md index d679463..07dd308 100644 --- a/README.md +++ b/README.md @@ -4,4 +4,4 @@ As a regular user you must use the official integrated application through [Umbr ![Umbrel](https://user-images.githubusercontent.com/45034541/140373859-66b7fa6d-5eeb-4fc5-8608-d139e8677267.png) -If you really want to tinker with this app, read [this](https://github.com/ln-markets/umbrel/blob/master/dev/README.MD) to know how to setup your env properly. +If you really want to tinker with this app, read [this](https://github.com/ln-markets/umbrel/tree/master/dev/README.md) to know how to setup your env properly. diff --git a/dev/README.md b/dev/README.md new file mode 100644 index 0000000..e029f96 --- /dev/null +++ b/dev/README.md @@ -0,0 +1,77 @@ +# Dev setup + +You must follow this if you want to work on this app. + +## Prerequisites: + +- [docker](https://docs.docker.com/get-docker/) +- [docker-compose](https://docs.docker.com/compose/install/) +- [jq](https://stedolan.github.io/jq/) + +## Install local env + +This environment is linked to the **regtest** version of LN Markets. **Meant only for LN Markets developers**. + +### Setting up the app: + +You must launch LN Markets local env beforehand. + +```shell + $> pnpm local:start +``` + +## Install testnet env + +This environment is linked to the **testnet** version of LN Markets. **Meant for development use only**. + +### Setting up the app: + +If it's the first time running the app in this mode, you must setup a channel between your node and LN Markets. + +```shell + $> pnpm testnet:init +``` + +This command will output you a wallet address that you must use to get tBTC in order to open a channel. You can get those via faucets, here is a small selection of them. + +| tBTC Faucets | +| :-----------------------------------: | +| https://coinfaucet.eu/en/btc-testnet/ | +| https://testnet-faucet.mempool.co/ | +| https://bitcoinfaucet.uo1.net/ | +| | + +You can check how much your wallet contains. + +```shell + $> pnpm lnd:balance +``` + +Now that you have money create a channel with LN Markets. + +```shell + $> pnpm lnd:create-channel AMOUNT +``` + +If it's not the first time simply start the env. + +```shell + $> pnpm testnet:start +``` + +In both case you'll have to unlock your wallet and restart the API to get access to your node! + +```shell + $> pnpm lnd:unlock + $> pnpm testnet:restart-api +``` + +## Services + +These following services ar now accessible on any web browser no matter which env you launched. + +| Service | URL | +| :-----: | :-----------------------: | +| API | http://localhost:8001/api | +| Front | http://localhost:3000 | +| | |