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

Gateway will use the default rpc client #2955

Open
douglaz opened this issue Aug 14, 2023 · 4 comments
Open

Gateway will use the default rpc client #2955

douglaz opened this issue Aug 14, 2023 · 4 comments
Labels
blocked Blocked on something. The author is responsible for making progress and unblocking it. lightning Lightning module
Milestone

Comments

@douglaz
Copy link
Contributor

douglaz commented Aug 14, 2023

It seems the gateway will try to use the bitcoind defined on the wallet module consensus configuration, like:

    "2": {
      "kind": "wallet",
      "client_default_bitcoin_rpc": {
        "kind": "esplora",
        "url": "http://127.0.0.1:50002/"
      },

Ignoring all local configuration like FM_BITCOIN_* variables

(Perhaps this problem isn't gateway specific and will happen with any client?)

@m1sterc001guy m1sterc001guy added the lightning Lightning module label Aug 15, 2023
@elsirion
Copy link
Contributor

elsirion commented Aug 15, 2023

Yes, the client doesn't take env vars into account. The problem is that there is a wide variety of client use cases and only a subset of them supports env vars, so it didn't occur to me.

I think it would be interesting to support as long as there is no better way of overriding this default (which will likely be stateful and more complex).

@justinmoon
Copy link
Contributor

justinmoon commented Aug 15, 2023

Gatewayd could read from env here and set the client bitcoin rpc inside WalletClientGen instead of just using WalletClientGen::default(). This seems cleaner than having client library read from environment.

@m1sterc001guy
Copy link
Contributor

This seems like a configuration that would be good to add to the gateway's config API: #3154

I think most gateway operators will only want to configure their bitcoind instance once, and not per-client.

@m1sterc001guy
Copy link
Contributor

This is blocked on updating bitcoincoire-rpc to 0.17.0. The client can't currently use bitcoind for RPCs because it calls import_address_script, which throws an error when called on descriptor wallets. I believe this needs to be upgraded to import_descriptors which is available in bitcoincore-rpc 0.17.0

@m1sterc001guy m1sterc001guy added the blocked Blocked on something. The author is responsible for making progress and unblocking it. label Oct 12, 2023
@justinmoon justinmoon modified the milestones: 0.2, 0.2.0, 0.2.1 Oct 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked Blocked on something. The author is responsible for making progress and unblocking it. lightning Lightning module
Projects
Status: On Deck
Development

No branches or pull requests

4 participants