Skip to content

Commit 1d132d1

Browse files
committed
lndclient: Add the watchtower client service
Add the watchtower client service to the macaroon recipe and to the main lnd services.
1 parent e90c814 commit 1d132d1

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

lnd_services.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -180,6 +180,7 @@ type LndServices struct {
180180
Router RouterClient
181181
Versioner VersionerClient
182182
State StateClient
183+
WtClient WatchtowerClientClient
183184

184185
ChainParams *chaincfg.Params
185186
NodeAlias string
@@ -385,6 +386,9 @@ func NewLndServices(cfg *LndServicesConfig) (*GrpcLndServices, error) {
385386
routerClient := newRouterClient(
386387
conn, macaroons[RouterServiceMac], timeout,
387388
)
389+
wtClientClient := newWtClientClient(
390+
conn, macaroons[WalletKitServiceMac], timeout,
391+
)
388392

389393
cleanup := func() {
390394
log.Debugf("Closing lnd connection")
@@ -416,6 +420,7 @@ func NewLndServices(cfg *LndServicesConfig) (*GrpcLndServices, error) {
416420
Router: routerClient,
417421
Versioner: versionerClient,
418422
State: stateClient,
423+
WtClient: wtClientClient,
419424
ChainParams: chainParams,
420425
NodeAlias: nodeAlias,
421426
NodePubkey: route.Vertex(nodeKey),

macaroon_recipes.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ var (
2121
"signrpc": (*SignerClient)(nil),
2222
"verrpc": (*VersionerClient)(nil),
2323
"walletrpc": (*WalletKitClient)(nil),
24+
"wtclientrpc": (*WatchtowerClientClient)(nil),
2425
}
2526

2627
// renames is a map of renamed RPC method names. The key is the name as

0 commit comments

Comments
 (0)