-
Notifications
You must be signed in to change notification settings - Fork 353
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
Add Bluewallet LNDHub #472
Conversation
Anyone else want to use native Bluewallet Lightning with their BTC Pay Server, this will enable it.
Use non-custodial LND Lightning directly from your Bluewallet, and freely let others open accounts on your node.
Can someone help to figure out the |
For reference: Prior discussion around the general topic in btcpayserver/btcpayserver#204 |
docker-compose-generator/docker-fragments/opt-add-bluewallet-lndhub.yml
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you change the docker compose version to match the existing ones?
Is it tested and working?
docker-compose-generator/docker-fragments/opt-add-bluewallet-lndhub.yml
Outdated
Show resolved
Hide resolved
Oops when I added mempool.space locally, with the intention to create a separate PR, it added it here to this one. Not sure how to avoid that, anyway, I think we can add both these with one PR, hope it is fine? |
Can you roll that back and open a separate PR? We should not mix those two concerns. |
Embarrasingly, I am not sure how to do that. Two of the files are the same between both PRs. I am editing locally my fork, and just saving, and it was "auto-added" to this PR.. |
Do you need to be walked through ? |
@maltokyo Here's how you can do it:
Now the PR should be ok again.
|
Cool, now the only thing that needs to be cleaned up is the conflict in the nginx template. I think it is there because kukks just merged the Sphinx PR and it also contained changes in that file. |
ok Ill wait for this one to be merged first, then do mempool after that @dennisreimann I don't know how to resolve that conflict. When I click resolve conflict here on the web version, I don't have any buttons that I can press on the following screen. It says that only people with write access to the repo can resolve that. Could you please help? |
@dennisreimann @Kukks - please let me know if anything else. If anyone else is keen to test, that is cool too |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Testing
I just tried to run it with the latest btcpayserver-docker installation. If someone else also wants to give it a try, you can deploy it as a custom fragment:
- SSH into your BTCPay Server and go to the main BTCPay Server directory (where the
btcpay-setup.sh
script is located) - Create the file
docker-compose-generator/docker-fragments/opt-add-bluewallet-lndhub.custom.yml
with the content ofopt-add-bluewallet-lndhub.yml
from this PR - Add the diff snippet from
Production/nginx.tmpl
to theProduction/nginx.tmpl
file on your server - Run the following commands:
export BTCPAYGEN_ADDITIONAL_FRAGMENTS="$BTCPAYGEN_ADDITIONAL_FRAGMENTS;opt-add-bluewallet-lndhub.custom"
. ./btcpay-setup.sh -i
Once the setup is done you can check the container log using docker logs -f generated_bluewallet_lndhub_app_1
.
Review
Here's what I came across with the current state:
ERROR: The Compose file '/root/btcpayserver/btcpayserver-docker/Generated/docker-compose.generated.yml' is invalid because:
Unsupported config option for services.bluewallet_lndhub_app: 'init'
Unsupported config option for services.bluewallet_lndhub_redis: 'init'
Once you remove the init: true
lines from the fragment it downloads and installs the container.
One more thing I noticed: You should add the docker info to the support table.
Remove init (not compatible with v3 of docker-compose) Update compatibility table
Thank you @dennisreimann - both fixed. Indeed, |
My guess is that it assumes to be deployed at the root instead of a subdirectory. Unfortunately I can't test it, because I'm still struggling to get the container installed (as said that's on my side), but I assume that your problem might be fixable by fiddling with the proxy_pass URI, like removing the trailing slash |
Finally got it! Thanks for the tip. Not sure if that's the correct way, but this now worked. WIth the exception of TOR, everything is done! I think it is ready for merging, but that is up to you guys @dennisreimann @Kukks - thanks for help as always. |
Awesome, congrats, that's very cool! 👍 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For tor support, it should be automatic (your own onion URL for btcpay +/bluewallet_lndhub_app/
)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dennisreimann any ideas?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested and it now works for me as well. One thing I noticed is that I can access the LNDhub app without being logged in to BTCPay. Is it supposed to work that way?
Yes, good observation @dennisreimann - and yes that is how it is supposed to work. It is an open page, for anyone (friends and family) to deposit on-chain BTC to set up a wallet, while the owner of the server takes all the heavy lifting of setting up channels and managing liquidity, etc. The worst that can happen is that some random person sends you some BTC on-chain... ;) You can see, Bluewallet themselves leave this page completely open: http://lndhub.io/ - if you trust them with your BTC, you can open a lightning wallet there, and use their liquidity and channels as your own. |
@Kukks - please let me know if anything from your side. I think it is good to go |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
minor last bits
docker-compose-generator/docker-fragments/opt-add-bluewallet-lndhub.yml
Outdated
Show resolved
Hide resolved
All done |
fixed up the last bits (you should check what I did for future features @maltokyo @dennisreimann ) |
Thanks Kukks!! Appreciate that, and learned for next one |
@Kukks Thanks, I didn't know about the script part :) |
Yes, it's a pretty awesome feature where you actually don't trust the built images and build everything you use yourself! |
This is HUGE! Does each store have it's own LNDhub account? Will be incredible for onboarding local businesses using my node! This is the dream! |
Anyone can make an account on it. They have to send you on chain BTC first. |
Worth noting that LNDHub accounts are NOT supported inside BTCPay Stores.
That requires additional dev work.
…On Thu, May 13, 2021 at 11:51 AM maltokyo ***@***.***> wrote:
Anyone can make an account on it. They have to send you on chain BTC first.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#472 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAN357TT4JJQH43IEJ5TA3DTNOOLBANCNFSM436UZBNA>
.
|
This will be huge. I went ahead and set up a full node b/c I couldn't find a way to accept Lightning without doing so on a hosted btcpay box, but most people won't do that. We could get so many more businesses on LN if all they had to do was set up a wallet on a smartphone app! |
@entreprenewer we are currently in the process of making LNbank a BTCPay Server plugin. It will enable this kind of functionality. https://github.com/dennisreimann/btcpayserver-lnbank |
Bluewallet LNDHub additional fragment:
Use non-custodial LND Lightning directly from your Bluewallet, and freely let others open accounts on your node.
@NicolasDorier I think there was some discussion on this, would it be appreciated? I will need some help with TOR activation and creating some variables and in general making this BTCPay friendly, etc if so. I was busy for the last months, but want to get back into BTCPay contributions now.
@Kukks I think you were looking at lnbits instead, but I personally use Bluewallet and I am not sure if they complement each other, or will clash? Please provide your view.