Skip to content

Lnd: Listen for RPC calls on a bufconn #5777

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

Merged
merged 3 commits into from
Oct 8, 2021

Conversation

orbitalturtle
Copy link
Contributor

This PR adds a couple of pieces that can help us run Terminal in stateless mode, described here: lightninglabs/lightning-terminal#160 (comment).

In short, the first commit adds a field to ListenerCfg for passing in a bufconn to LND, which can be used to listen in-memory RPC calls. It also allows us to pass the admin macaroon back to the program calling LND via a channel.

The second commit adds a GetAllPermissions function that can be used by Terminal to retrieve all the permissions required by LND to bake a "super macaroon" that can be used to interact with lnd as well as Terminal's sub daemons.

(I will also submit a PR to Terminal soon which will show how this all ties together.)

@orbitalturtle orbitalturtle force-pushed the buf-pass-macaroon branch 3 times, most recently from 427cdbf to 2c72f9a Compare September 24, 2021 21:51
Copy link
Collaborator

@guggero guggero left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the changes, code looks almost ready now!
Just a few more nits and questions.

Copy link
Collaborator

@guggero guggero left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Turned out great 💯

Just one more comment, then we're good to go IMO.

@orbitalturtle
Copy link
Contributor Author

@guggero Terrific, made those changes

@orbitalturtle orbitalturtle requested a review from guggero October 1, 2021 01:33
@Roasbeef
Copy link
Member

Roasbeef commented Oct 1, 2021

Needs a rebase!

Copy link
Member

@Roasbeef Roasbeef left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM ✨

Just a few style nits.

Copy link
Collaborator

@guggero guggero left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM pending @Roasbeef's nits.

Copy link
Member

@Roasbeef Roasbeef left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🍚

@Roasbeef Roasbeef merged commit d630b95 into lightningnetwork:master Oct 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants