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

multi: add DisableUI option #519

Merged
merged 5 commits into from
Mar 17, 2023
Merged

Conversation

ellemouton
Copy link
Member

@ellemouton ellemouton commented Mar 16, 2023

With this option set, the local UI will not be served and so the UI password does not need to be set.

To make use of this, you can remove the --uipassword= from your config file (or command line argument)
And can instead add --disableui.

To test, start up Litd with the above options and see that navigating to "localhost:8448" now returns a 401.

Also adds new commands to litcli:

$ litcli stop
$ litcli getinfo

Fixes: #448

@ellemouton ellemouton force-pushed the disableui branch 5 times, most recently from 719b306 to f9aa1c4 Compare March 16, 2023 12:22
@ellemouton ellemouton requested a review from guggero March 16, 2023 12:54
Copy link
Member

@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.

Great work on this 🚀 Really love the new itest setup, very thorough.
Just one comment about the Ping service, other than that this looks good to me.

litrpc/proxy.proto Outdated Show resolved Hide resolved
itest/litd_node.go Outdated Show resolved Hide resolved
terminal.go Outdated Show resolved Hide resolved
config.go Show resolved Hide resolved
itest/litd_node.go Show resolved Hide resolved
itest/litd_mode_integrated_test.go Show resolved Hide resolved
In this commit, a new Proxy service is added with a StopDaemon method.
This method can be used to stop the Litd service. This will be useful in
remote-mode itests where we want to restart Litd without also restarting
LND. It also provides a nice way of shutting down Litd in remote-mode.
A GetInfo method is also added to the service which for now just returns
the Litd version. The reason for adding this method now is so that
access to the new Proxy service can be tested in the itests withouth
actually shutting down Litd.
Let the itest framework make use of the new StopDaemon method. When
instructed to Stop the node, if it is running in remote mode then only
the litd node itself should be stopped and not the remote LND node.
Add a new `disableui` config option. If this option is set then the user
no longer needs to set the `uipassword` config option. This also means
that the user will no longer be able to interact with the local UI.
Add new `WithoutLitArg` and `WithLitArg` functional options that can be
passed to `GenArgs` when a node is being restarted. This makes it easy
to change the arguments of a node on restart.
Copy link
Member Author

@ellemouton ellemouton 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 speedy review @guggero! Added the GetInfo method 👍

litrpc/proxy.proto Outdated Show resolved Hide resolved
Copy link
Member

@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 🎉

@ellemouton ellemouton requested a review from jamaljsr March 17, 2023 09:30
Copy link
Member

@jamaljsr jamaljsr left a comment

Choose a reason for hiding this comment

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

tACK Awesome update!🔥

Tested --disablui with no password. The CLIs for lnd/loop/pool worked fine. I created a session with litcli and was able to connect and use Terminal Web with no issues. Great work.

@guggero guggero merged commit f52b046 into lightninglabs:master Mar 17, 2023
@ellemouton ellemouton deleted the disableui branch March 17, 2023 20:14
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.

Add option to disable the local UI
3 participants