Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Weekly cleanups #3636

Merged
merged 5 commits into from
Apr 10, 2020
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
doc: Give an example of the supported DSN formats
I was told that DSNs are not trivial to format, so this adds an example to
help setup the postgres wallet backend.
  • Loading branch information
cdecker committed Apr 10, 2020
commit 17686aedc0b6c5c3e655e4574fdf8b6d0252caba
26 changes: 25 additions & 1 deletion doc/lightningd-config.5
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,30 @@ name, including a scheme such as \fBsqlite3\fR or \fBpostgres\fR followed by the
connection parameters\.


The default wallet corresponds to the following DSN:

.nf
.RS
--wallet=sqlite3://$HOME/.lightning/bitcoin/lightningd.sqlite3
.RE

.fi

The following is an example of a postgresql wallet DSN:

.nf
.RS
--wallet=postgres://user:pass@localhost:5432/db_name
.RE

.fi

This will connect to a the DB server running on \fBlocalhost\fR port \fB5432\fR,
authenticate with username \fBuser\fR and password \fBpass\fR, and then use the
database \fBdb_name\fR\. The database must exist, but the schema will be managed
automatically by \fBlightningd\fR\.


\fBencrypted-hsm\fR
If set, you will be prompted to enter a password used to encrypt the \fBhsm_secret\fR\.
Note that once you encrypt the \fBhsm_secret\fR this option will be mandatory for
Expand Down Expand Up @@ -283,7 +307,7 @@ extremely busy node for you to even notice\.

\fBlarge-channels\fR
Removes capacity limits for channel creation\. Version 1\.0 of the specification
limited channel sizes to 16777216 satoshi\. With this option (which your
limited channel sizes to 16777215 satoshi\. With this option (which your
node will advertize to peers), your node will accept larger incoming channels
and if the peer supports it, will open larger channels\. Note: this option
is spelled \fBlarge-channels\fR but it's pronounced \fBwumbo\fR\.
Expand Down
17 changes: 17 additions & 0 deletions doc/lightningd-config.5.md
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,23 @@ Identify the location of the wallet. This is a fully qualified data source
name, including a scheme such as `sqlite3` or `postgres` followed by the
connection parameters.

The default wallet corresponds to the following DSN:

```
--wallet=sqlite3://$HOME/.lightning/bitcoin/lightningd.sqlite3
```

The following is an example of a postgresql wallet DSN:

```
--wallet=postgres://user:pass@localhost:5432/db_name
```

This will connect to a the DB server running on `localhost` port `5432`,
authenticate with username `user` and password `pass`, and then use the
database `db_name`. The database must exist, but the schema will be managed
automatically by `lightningd`.

**encrypted-hsm**
If set, you will be prompted to enter a password used to encrypt the `hsm_secret`.
Note that once you encrypt the `hsm_secret` this option will be mandatory for
Expand Down