Skip to content

Commit ef624d8

Browse files
committed
docs: add pool examples
1 parent a48fcf4 commit ef624d8

File tree

6 files changed

+103
-29
lines changed

6 files changed

+103
-29
lines changed

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@ Lightning Terminal (LiT) is a browser-based interface for managing channel liqui
1010
- Visualize your channels and balances
1111
- Perform submarine swaps via the [Lightning Loop](https://lightning.engineering/loop) service
1212
- Classify channels according to your node's operating mode
13-
- Run a single binary that integrates both [`loopd`](https://github.com/lightninglabs/loop) and [`faraday`](https://github.com/lightninglabs/faraday) daemons all in one
13+
- Run a single binary that integrates [`loopd`](https://github.com/lightninglabs/loop),
14+
[`poold`](https://github.com/lightninglabs/pool) and
15+
[`faraday`](https://github.com/lightninglabs/faraday) daemons all in one
1416

1517
## Installation
1618
Download the latest binaries from the [releases](https://github.com/lightninglabs/lightning-terminal/releases) page.

doc/compile.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,9 @@ $ make install
2020
```
2121

2222
This will produce the `litd` executable and add it to your `GOPATH`. The CLI binaries for
23-
`lncli`, `loop`, and `frcli` are not created by `make install`. You will need to download
24-
those binaries from the [lnd](https://github.com/lightningnetwork/lnd/releases),
25-
[loop](https://github.com/lightninglabs/loop/releases), and
23+
`lncli`, `loop`, `pool`, and `frcli` are not created by `make install`. You will
24+
need to download those binaries from the
25+
[lnd](https://github.com/lightningnetwork/lnd/releases),
26+
[loop](https://github.com/lightninglabs/loop/releases),
27+
[pool](https://github.com/lightninglabs/pool/releases), and
2628
[faraday](https://github.com/lightninglabs/faraday/releases) repos manually.

doc/config-lnd-integrated.md

Lines changed: 27 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22

33
The "integrated" mode means that `lnd` is started within the same process as
44
`litd`, alongside the UI server. Once the integrated `lnd` has been unlocked,
5-
`litd` then goes ahead and starts `faraday` and `loop` and connects them to the
6-
integrated `lnd` node.
5+
`litd` then goes ahead and starts `faraday`, `pool` and `loop` and connects them
6+
to the integrated `lnd` node.
77

8-
Currently the UI server cannot connect to `loop` or `faraday` daemons that
9-
aren't running in the same process. But that feature will also be available in
10-
future versions.
8+
Currently the UI server cannot connect to `loop`, `pool` or `faraday` daemons
9+
that aren't running in the same process. But that feature will also be available
10+
in future versions.
1111

1212
## Use command line parameters only
1313

@@ -99,6 +99,9 @@ lnd.bitcoind.zmqpubrawtx=localhost:28333
9999
# Loop
100100
loop.loopoutmaxparts=5
101101
102+
# Pool
103+
pool.newnodesonly=true
104+
102105
# Faraday
103106
faraday.min_monitored=48h
104107
@@ -314,6 +317,25 @@ You can easily create an alias for this by adding the following line to your
314317
alias lit-loop="loop --rpcserver=localhost:10009 --tlscertpath=~/.lnd/tls.cert --macaroonpath=~/.loop/testnet/loop.macaroon"
315318
```
316319

320+
### Example `pool` command
321+
322+
Again, `poold` also runs on the same gRPC server as `lnd` and we have to specify
323+
the `host:port` and the TLS certificate of `lnd` but use the macaroon from the
324+
`.pool` directory.
325+
326+
```shell script
327+
$ pool --rpcserver=localhost:10009 --tlscertpath=~/.lnd/tls.cert \
328+
--macaroonpath=~/.pool/testnet/pool.macaroon \
329+
accounts list
330+
```
331+
332+
You can easily create an alias for this by adding the following line to your
333+
`~/.bashrc` file:
334+
335+
```shell script
336+
alias lit-pool="pool --rpcserver=localhost:10009 --tlscertpath=~/.lnd/tls.cert --macaroonpath=~/.pool/testnet/pool.macaroon"
337+
```
338+
317339
### Example `frcli` command
318340

319341
Faraday's command line tool follows the same pattern as loop. We also have to

doc/config-lnd-remote.md

Lines changed: 46 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -54,34 +54,36 @@ Visit https://localhost:8443 to access LiT.
5454

5555
The "remote" mode means that `lnd` is started as a standalone process, possibly on another
5656
host, and `litd` connects to it, right after starting its UI server. Once the connection
57-
to the remote `lnd` node has been established, `litd` then goes ahead and starts `faraday`
58-
and `loop` and connects them to that `lnd` node as well.
57+
to the remote `lnd` node has been established, `litd` then goes ahead and starts
58+
`faraday`, `pool` and `loop` and connects them to that `lnd` node as well.
5959

60-
Currently the UI server cannot connect to `loop` or `faraday` daemons that aren't running
61-
in the same process. But that feature will also be available in future versions.
60+
Currently the UI server cannot connect to `loop`, `pool` or `faraday` daemons
61+
that aren't running in the same process. But that feature will also be available
62+
in future versions.
6263

6364
## Use command line parameters only
6465

6566
In addition to the LiT specific and remote `lnd` parameters, you must also provide
66-
configuration to the `loop` and `faraday` daemons. For the remote `lnd` node, all
67+
configuration to the `loop`, `pool`, and `faraday` daemons. For the remote `lnd` node, all
6768
`remote.lnd` flags must be specified. Note that `loopd` and `faraday` will automatically
6869
connect to the same remote `lnd` node, so you do not need to provide them with any
6970
additional parameters unless you want to override them. If you do override them, be sure
70-
to add the `loop.` and `faraday.` prefixes.
71+
to add the `loop.`, `pool.`, and `faraday.` prefixes.
7172

7273
To see all available command line options, run `litd --help`.
7374

74-
The most minimal example command to start `litd` and connect it to a local `lnd` node that
75-
is running with default configuration settings is:
75+
The most minimal example command to start `litd` and connect it to a local `lnd`
76+
node that is running with default configuration settings is:
7677

7778
```shell script
7879
$ litd --uipassword=My$trongP@ssword
7980
```
8081

8182
All other command line flags are only needed to overwrite the default behavior.
8283

83-
Here is an example command to start `litd` connected to a testnet `lnd` that is running on
84-
another host and overwrites a few default settings in `loop` and `faraday` (optional):
84+
Here is an example command to start `litd` connected to a testnet `lnd` that is
85+
running on another host and overwrites a few default settings in `loop`, `pool`,
86+
and `faraday` (optional):
8587

8688
```shell script
8789
$ litd \
@@ -96,17 +98,19 @@ $ litd \
9698
--remote.lnd.macaroondir=/some/folder/with/lnd/data \
9799
--remote.lnd.tlscertpath=/some/folder/with/lnd/data/tls.cert \
98100
--loop.loopoutmaxparts=5 \
101+
--pool.newnodesonly=true \
99102
--faraday.min_monitored=48h \
100103
--faraday.connect_bitcoin \
101104
--faraday.bitcoin.host=some-other-host \
102105
--faraday.bitcoin.user=testnetuser \
103106
--faraday.bitcoin.password=testnetpw
104107
```
105108

106-
NOTE: Even though LiT itself only needs `lnd`'s `admin.macaroon`, the `loop` and `faraday`
107-
daemons will require other macaroons and will look for them in the folder specified with
108-
`--remote.lnd.macaroondir`. It is advised to copy all `*.macaroon` files and the
109-
`tls.cert` file from the remote host to the host that is running `litd`.
109+
NOTE: Even though LiT itself only needs `lnd`'s `admin.macaroon`, the `loop`,
110+
`pool`, and `faraday` daemons will require other macaroons and will look for
111+
them in the folder specified with `--remote.lnd.macaroondir`. It is advised to
112+
copy all `*.macaroon` files and the `tls.cert` file from the remote host to the
113+
host that is running `litd`.
110114

111115
## Use a configuration file
112116

@@ -130,8 +134,8 @@ uipassword=My$trongP@ssword
130134
All other configuration settings are only needed to overwrite the default behavior.
131135

132136
Here is an example `~/.lit/lit.conf` file that connects LiT to a testnet `lnd` node
133-
running on another host and overwrites a few default settings in `loop` and `faraday`
134-
(optional):
137+
running on another host and overwrites a few default settings in `loop`, `pool`,
138+
and `faraday` (optional):
135139

136140
```text
137141
# Application Options
@@ -153,6 +157,9 @@ remote.lnd.tlscertpath=/some/folder/with/lnd/data/tls.cert
153157
# Loop
154158
loop.loopoutmaxparts=5
155159
160+
# Pool
161+
pool.newnodesonly=true
162+
156163
# Faraday
157164
faraday.min_monitored=48h
158165
@@ -189,10 +196,10 @@ remote.lnd.macaroondir=/some/folder/with/lnd/data
189196
remote.lnd.tlscertpath=/some/folder/with/lnd/data/tls.cert
190197
```
191198

192-
Because in the remote `lnd` mode all other LiT components (`loop`, `faraday` and the UI
193-
server) listen on the same port (`443` in this example) and use the same TLS certificate
194-
(`~/.lit/tls.cert` in this example), some command line calls now need some extra options
195-
that weren't necessary before.
199+
Because in the remote `lnd` mode all other LiT components (`loop`, `pool`,
200+
`faraday` and the UI server) listen on the same port (`443` in this example) and
201+
use the same TLS certificate (`~/.lit/tls.cert` in this example), some command
202+
line calls now need some extra options that weren't necessary before.
196203

197204
**NOTE**: All mentioned command line tools have the following behavior in common: You
198205
either specify the `--network` flag and the `--tlscertpath` and `--macaroonpath` are
@@ -233,6 +240,25 @@ file:
233240
alias lit-loop="loop --rpcserver=localhost:443 --tlscertpath=~/.lit/tls.cert --macaroonpath=~/.loop/testnet/loop.macaroon"
234241
```
235242

243+
### Example `pool` command
244+
245+
Again, `poold` also runs on the same port as the UI server and we have to
246+
specify the `host:port` and the TLS certificate of LiT but use the macaroon from
247+
the `.pool` directory.
248+
249+
```shell script
250+
$ pool --rpcserver=localhost:443 --tlscertpath=~/.lit/tls.cert \
251+
--macaroonpath=~/.pool/testnet/pool.macaroon \
252+
accounts list
253+
```
254+
255+
You can easily create an alias for this by adding the following line to your
256+
`~/.bashrc` file:
257+
258+
```shell script
259+
alias lit-pool="pool --rpcserver=localhost:443 --tlscertpath=~/.lit/tls.cert --macaroonpath=~/.pool/testnet/pool.macaroon"
260+
```
261+
236262
### Example `frcli` command
237263

238264
Faraday's command line tool follows the same pattern as loop. We also have to specify the

doc/letsencrypt.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,27 @@ file:
112112
alias lit-loop="loop --rpcserver=terminal.mydomain.com:8443 --tlscertpath=~/.lit/letsencrypt/terminal.mydomain.com --macaroonpath=~/.loop/testnet/loop.macaroon"
113113
```
114114

115+
### Example `pool` command
116+
117+
Since `poold` also runs on the same gRPC server as `lnd`, we have to specify the
118+
**LetEncrypt** `host:port` and TLS certificate. But `poold` verifies its own
119+
macaroon, so we have to specify that one from the `.pool` directory.
120+
121+
```shell script
122+
$ pool \
123+
--rpcserver=terminal.mydomain.com:8443 \
124+
--tlscertpath=~/.lit/letsencrypt/terminal.mydomain.com \
125+
--macaroonpath=~/.pool/testnet/pool.macaroon \
126+
accounts list
127+
```
128+
129+
You can easily create an alias for this by adding the following line to your
130+
`~/.bashrc` file:
131+
132+
```shell script
133+
alias lit-pool="pool --rpcserver=terminal.mydomain.com:8443 --tlscertpath=~/.lit/letsencrypt/terminal.mydomain.com --macaroonpath=~/.loop/testnet/loop.macaroon"
134+
```
135+
115136
### Example `frcli` command
116137

117138
Faraday's command line tool follows the same pattern as loop. We also have to specify the

doc/troubleshooting.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ If you have trouble running your node, please first check the logs for warnings
44
If there are errors relating to one of the embedded servers, then you should open an issue
55
in their respective GitHub repos ([lnd](https://github.com/lightningnetwork/lnd/issues),
66
[loop](https://github.com/lightninglabs/loop/issues),
7+
[pool](https://github.com/lightninglabs/pool/issues),
78
[faraday](https://github.com/lightninglabs/faraday/issues). If the issue is related to the
89
web app, then you should open an
910
[issue](https://github.com/lightninglabs/lightning-terminal/issues) here in this repo.

0 commit comments

Comments
 (0)