You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Shushtar is a browser-based interface for managing the off-chain liquidity of your `lnd` Lightning Network node. It presents a visual representation of your channels and balances, while allowing you to perform submarine swaps via the [Lightning Loop](https://lightning.engineering/loop) service using a graphical interface. With a bird's eye view of all of your open channels, you can instantly see which ones need your immediate attention.
7
+
Shushtar is a browser-based interface for managing the off-chain liquidity of your `lnd`
8
+
Lightning Network node. It presents a visual representation of your channels and balances,
9
+
while allowing you to perform submarine swaps via the
10
+
[Lightning Loop](https://lightning.engineering/loop) service using a graphical interface.
11
+
With a bird's eye view of all of your open channels, you can instantly see which ones need
12
+
your immediate attention.
8
13
9
14
You can configure the UI to classify channels according to your node's operating mode.
10
15
11
-
-**Optimize for Receiving**: For merchants who primarily receive inbound Lightning payments, the channels with high local balances will be shaded red.
12
-
-**Optimize for Routing**: For routing node operators, that want to keep their channels balanced close to 50%, the channels with a high balance in either direction will be flagged.
13
-
-**Optimize for Sending**: For exchanges, fiat gateways, and other operators who primarily send outgoing Lightning payments, the channels with high local balances will be shaded red.
16
+
-**Optimize for Receiving**: For merchants who primarily receive inbound Lightning
17
+
payments, the channels with high local balances will be shaded red.
18
+
-**Optimize for Routing**: For routing node operators, that want to keep their channels
19
+
balanced close to 50%, the channels with a high balance in either direction will be
20
+
flagged.
21
+
-**Optimize for Sending**: For exchanges, fiat gateways, and other operators who
22
+
primarily send outgoing Lightning payments, the channels with high local balances will
23
+
be shaded red.
14
24
15
25
## Architecture
16
26
17
-
Shushtar is packaged as a single binary which contains the [`lnd`](https://github.com/lightningnetwork/lnd), [`loopd`](https://github.com/lightninglabs/loop) and [`faraday`](https://github.com/lightninglabs/faraday) daemons all in one. It also contains an HTTP server to serve the web assets (html/js/css) and a GRPC proxy to forward web requests from the browser to the appropriate GRPC server. This deployment strategy was chosen as it greatly simplifies the operational overhead of installation, configuration and maintenance that would be necessary to run each of these servers independently. You only need to download one executable and run one command to get Shushtar up and running. We include the CLI binaries `lncli`, `loop` and `frcli` for convenience in the downloadable archives as well.
27
+
Shushtar is packaged as a single binary which contains the
28
+
[`lnd`](https://github.com/lightningnetwork/lnd),
29
+
[`loopd`](https://github.com/lightninglabs/loop) and
30
+
[`faraday`](https://github.com/lightninglabs/faraday) daemons all in one. It also contains
31
+
an HTTP server to serve the web assets (html/js/css) and a GRPC proxy to forward web
32
+
requests from the browser to the appropriate GRPC server. This deployment strategy was
33
+
chosen as it greatly simplifies the operational overhead of installation, configuration
34
+
and maintenance that would be necessary to run each of these servers independently. You
35
+
only need to download one executable and run one command to get Shushtar up and running.
36
+
We include the CLI binaries `lncli`, `loop` and `frcli` for convenience in the
37
+
downloadable archives as well.
18
38
19
39
## Installation
20
40
21
-
There are two options for installing Shushtar: download the published binaries for your platform, or compile from source code.
41
+
There are two options for installing Shushtar: download the published binaries for your
42
+
platform, or compile from source code.
22
43
23
44
#### Download Binaries
24
45
25
-
Shushtar binaries for many platforms are made available on the GitHub [Releases](https://github.com/lightninglabs/shushtar/releases) page in this repo. There you can download the latest version and extract the archive into a directory on your computer.
46
+
Shushtar binaries for many platforms are made available on the GitHub
47
+
[Releases](https://github.com/lightninglabs/shushtar/releases) page in this repo. There
48
+
you can download the latest version and extract the archive into a directory on your
49
+
computer.
26
50
27
51
#### Compile from Source Code
28
52
29
-
To compile from source code, you'll need to have some prerequisite developer tooling installed on your machine.
53
+
To compile from source code, you'll need to have some prerequisite developer tooling
54
+
installed on your machine.
30
55
31
-
-**Go**: Shushtar's backend web server is written in Go. Instructions for installing Go for your operating system can be found on the [golang install](https://golang.org/doc/install) page. The minimum version supported is Go v1.13.
32
-
-**NodeJS**: Shushtar's frontend is written in TypeScript and built on top of the React JS web framework. To bundle the assets into Javascript & CSS compatible with web browsers, NodeJS is required. It can be downloaded and installed by following the instructions on the [NodeJS download](https://nodejs.org/en/download/) page.
33
-
-**Yarn**: a popular package manager for NodeJS application dependencies. Installation information can be found on the [Yarn Installation](https://classic.yarnpkg.com/en/docs/install) page.
56
+
-**Go**: Shushtar's backend web server is written in Go. Instructions for installing Go
57
+
for your operating system can be found on the
58
+
[golang install](https://golang.org/doc/install) page. The minimum version supported is
59
+
Go v1.13.
60
+
-**NodeJS**: Shushtar's frontend is written in TypeScript and built on top of the React
61
+
JS web framework. To bundle the assets into Javascript & CSS compatible with web
62
+
browsers, NodeJS is required. It can be downloaded and installed by following the
63
+
instructions on the [NodeJS download](https://nodejs.org/en/download/) page.
64
+
-**Yarn**: a popular package manager for NodeJS application dependencies. Installation
@@ -48,13 +82,26 @@ Shushtar only has a few configuration parameters itself.
48
82
49
83
#### Required
50
84
51
-
You must set `httpslisten` to the host & port that the https server should listen on. Also set `uipassword` to a strong password to use to login to the website in your browser. A minimum of 8 characters is required. In a production environment, it's recommended that you store this password as an environment variable.
85
+
You must set `httpslisten` to the host & port that the https server should listen on. Also
86
+
set `uipassword` to a strong password to use to login to the website in your browser. A
87
+
minimum of 8 characters is required. In a production environment, it's recommended that
88
+
you store this password as an environment variable.
52
89
53
90
#### Optional
54
91
55
-
You can also configure the HTTP server to automatically install a free SSL certificate provided by [LetsEncrypt](https://letsencrypt.org/). This is recommended if you plan to access the website from a remote computer and do not want to deal with the browser warning you about the self-signed certificate. You just need to specify the domain name you wish to use, and make sure port 80 is open in your in your firewall. LetsEncrypt requires this to verify that you own the domain name. Shushtar will listen on port 80 to handle the verification requests. On some linux-based platforms, you may need to run Shushtar with superuser privileges since port 80 is a system port.
92
+
You can also configure the HTTP server to automatically install a free SSL certificate
93
+
provided by [LetsEncrypt](https://letsencrypt.org/). This is recommended if you plan to
94
+
access the website from a remote computer and do not want to deal with the browser warning
95
+
you about the self-signed certificate. You just need to specify the domain name you wish
96
+
to use, and make sure port 80 is open in your in your firewall. LetsEncrypt requires this
97
+
to verify that you own the domain name. Shushtar will listen on port 80 to handle the
98
+
verification requests. On some linux-based platforms, you may need to run Shushtar with
99
+
superuser privileges since port 80 is a system port.
56
100
57
-
> Note: Shushtar only serves content over **HTTPS**. If you do not use `letsencrypt`, Shushtar will use the self-signed certificate that is auto-generated by `lnd` to encrypt the browser-to-server communication. Web browsers will display a warning when using the self-signed certificate.
101
+
> Note: Shushtar only serves content over **HTTPS**. If you do not use `letsencrypt`,
102
+
> Shushtar will use the self-signed certificate that is auto-generated by `lnd` to encrypt
103
+
> the browser-to-server communication. Web browsers will display a warning when using the
In addition to the Shushtar specific parameters, you must also provide configuration to the `lnd`, `loop` and `faraday` daemons. For `lnd`, each flag must be prefixed with `lnd.` (ex: `lnd.lnddir=~/.lnd`). Please see the [sample-lnd.conf](https://github.com/lightningnetwork/lnd/blob/master/sample-lnd.conf) file for more details on the available parameters. Note that `loopd` and `faraday` will automatically connect to the in-process `lnd` node, so you do not need to provide them with any additional parameters unless you want to override them. If you do override them, be sure to add the `loop.` and `faraday.` prefixes.
119
+
In addition to the Shushtar specific parameters, you must also provide configuration to
120
+
the `lnd`, `loop` and `faraday` daemons. For `lnd`, each flag must be prefixed with `lnd.`
file for more details on the available parameters. Note that `loopd` and `faraday` will
124
+
automatically connect to the in-process `lnd` node, so you do not need to provide them
125
+
with any additional parameters unless you want to override them. If you do override them,
126
+
be sure to add the `loop.` and `faraday.` prefixes.
73
127
74
128
Here is an example command to start `shushtar` on testnet with a local `bitcoind` node:
75
129
@@ -97,14 +151,13 @@ $ ./shushtar \
97
151
--faraday.min_monitored=48h
98
152
```
99
153
100
-
You can also store the configuration in a persistent `lnd.conf` file so you do
101
-
not need to type in the command line arguments every time you start the server.
102
-
Just remember to use the appropriate prefixes as necessary.
154
+
You can also store the configuration in a persistent `lnd.conf` file so you do not need to
155
+
type in the command line arguments every time you start the server. Just remember to use
156
+
the appropriate prefixes as necessary.
103
157
104
-
Also make sure to include the `lnd` general options in the `[Application Options]`
105
-
section because the section name `[Lnd]` is not unique anymore because of how we
106
-
combine the configurations of all daemons. This will hopefully be fixed in a
107
-
future release.
158
+
Also make sure to include the `lnd` general options in the `[Application Options]` section
159
+
because the section name `[Lnd]` is not unique anymore because of how we combine the
160
+
configurations of all daemons. This will hopefully be fixed in a future release.
108
161
109
162
Example `lnd.conf`:
110
163
@@ -149,36 +202,48 @@ The default location for the `lnd.conf` file will depend on your operating syste
149
202
150
203
### Upgrade Existing Nodes
151
204
152
-
If you already have existing `lnd`, `loop`, or `faraday` nodes, you can easily upgrade them to the Shushtar single executable while keeping all of your past data.
205
+
If you already have existing `lnd`, `loop`, or `faraday` nodes, you can easily upgrade
206
+
them to the Shushtar single executable while keeping all of your past data.
153
207
154
208
For `lnd`:
155
209
156
-
- if you use an `lnd.conf` file for configurations, add the `lnd.` prefix to each of the configuration parameters.
157
-
210
+
- if you use an `lnd.conf` file for configurations, add the `lnd.` prefix to each of the
211
+
configuration parameters.
212
+
158
213
Before:
214
+
159
215
```
160
216
[Application Options]
161
217
alias=merchant
162
218
```
219
+
163
220
After:
221
+
164
222
```
165
223
[Application Options]
166
224
lnd.alias=merchant
167
225
```
168
-
- if you use command line arguments for configuration, add the `lnd.` prefix to each argument to `shushtar`
169
-
226
+
227
+
- if you use command line arguments for configuration, add the `lnd.` prefix to each
- if you use an `loop.conf` file for configurations, copy the parameters into the `lnd.conf` file that `shushtar` uses, and add the `loop.` prefix to each of the configuration parameters.
244
+
- if you use an `loop.conf` file for configurations, copy the parameters into the
245
+
`lnd.conf` file that `shushtar` uses, and add the `loop.` prefix to each of the
246
+
configuration parameters.
182
247
183
248
Before: (in `loop.conf`)
184
249
@@ -194,64 +259,91 @@ For `loop`:
194
259
loop.loopoutmaxparts=5
195
260
```
196
261
197
-
- if you use command line arguments for configuration, add the `loop.` prefix to each argument to `shushtar`
198
-
262
+
- if you use command line arguments for configuration, add the `loop.` prefix to each
- the standalone `faraday` daemon does not load configuration from a file, but you can now store the parameters into the `lnd.conf` file that `shushtar` uses. Just add the `faraday.` prefix to each of the configuration parameters.
279
+
- the standalone `faraday` daemon does not load configuration from a file, but you can now
280
+
store the parameters into the `lnd.conf` file that `shushtar` uses. Just add the
281
+
`faraday.` prefix to each of the configuration parameters.
211
282
212
283
Before: (from command line)
284
+
213
285
```
214
286
$ faraday --min_monitored=48h
215
287
```
288
+
216
289
After: (in `lnd.conf`)
290
+
217
291
```
218
292
[Faraday]
219
293
faraday.min_monitored=48h
220
294
```
221
295
222
-
- if you use command line arguments for configuration, add the `faraday.` prefix to each argument to `shushtar`
223
-
296
+
- if you use command line arguments for configuration, add the `faraday.` prefix to each
If you have trouble running your node, please first check the logs for warnings or errors. If there are errors relating to one of the embedded servers, then you should open an issue in their respective GitHub repos ([lnd](https://github.com/lightningnetwork/lnd/issues), [loop](https://github.com/lightninglabs/loop/issues), [faraday](https://github.com/lightninglabs/faraday/issues). If the issue is related to the web app, then you should open an [issue](https://github.com/lightninglabs/shushtar/issues) here in this repo.
313
+
If you have trouble running your node, please first check the logs for warnings or errors.
314
+
If there are errors relating to one of the embedded servers, then you should open an issue
315
+
in their respective GitHub repos ([lnd](https://github.com/lightningnetwork/lnd/issues),
[faraday](https://github.com/lightninglabs/faraday/issues). If the issue is related to the
318
+
web app, then you should open an [issue](https://github.com/lightninglabs/shushtar/issues)
319
+
here in this repo.
236
320
237
321
#### Server
238
322
239
-
Server-side logs are stored in the directory specified by `lnd.lnddir` in your configuration. Inside, there is a `logs` dir containing the log files in subdirectories. Be sure to set `lnd.debuglevel=debug` in your configuration to see the most verbose logging information.
323
+
Server-side logs are stored in the directory specified by `lnd.lnddir` in your
324
+
configuration. Inside, there is a `logs` dir containing the log files in subdirectories.
325
+
Be sure to set `lnd.debuglevel=debug` in your configuration to see the most verbose
326
+
logging information.
240
327
241
328
#### Browser
242
329
243
-
Client-side logs are disabled by default in production builds. Logging can be turned on by adding a couple keys to your browser's `localStorage`. Simply run these two JS statements in you browser's DevTools console then refresh the page:
330
+
Client-side logs are disabled by default in production builds. Logging can be turned on by
331
+
adding a couple keys to your browser's `localStorage`. Simply run these two JS statements
332
+
in you browser's DevTools console then refresh the page:
The value for `debug` is a namespace filter which determines which portions of the app to display logs for. The namespaces currently used by the app are as follows:
338
+
The value for `debug` is a namespace filter which determines which portions of the app to
339
+
display logs for. The namespaces currently used by the app are as follows:
250
340
251
341
-`main`: logs general application messages
252
342
-`action`: logs all actions that modify the internal application state
253
343
-`grpc`: logs all GRPC API requests and responses
254
344
255
-
Example filters: `main,action` will only log main and action messages. `*,-action` will log everything except action messages.
345
+
Example filters: `main,action` will only log main and action messages. `*,-action` will
346
+
log everything except action messages.
256
347
257
-
The value for `debug-level` determines the verbosity of the logs. The value can be one of `debug`, `info`, `warn`, or `error`.
348
+
The value for `debug-level` determines the verbosity of the logs. The value can be one of
0 commit comments