lotus-wallet: Describe setup with auth

This commit is contained in:
Łukasz Magiera 2021-05-31 14:33:54 +02:00
parent 7d1ae7daf5
commit 937366f04a

View File

@ -52,6 +52,17 @@ func main() {
Name: "lotus-wallet", Name: "lotus-wallet",
Usage: "Basic external wallet", Usage: "Basic external wallet",
Version: build.UserVersion(), Version: build.UserVersion(),
Description: `
lotus-wallet provides a remote wallet service for lotus.
To configure your lotus node to use a remote wallet:
* Run 'lotus-wallet get-api-key' to generate API key
* Start lotus-wallet using 'lotus-wallet run' (see --help for additional flags)
* Edit lotus config (~/.lotus/config.toml)
* Find the '[Wallet]' section
* Set 'RemoteBackend' to '[api key]:http://[wallet ip]:[wallet port]'
(the default port is 1777)
* Start (or restart) the lotus daemon`,
Flags: []cli.Flag{ Flags: []cli.Flag{
&cli.StringFlag{ &cli.StringFlag{
Name: FlagWalletRepo, Name: FlagWalletRepo,
@ -78,7 +89,7 @@ func main() {
var getApiKeyCmd = &cli.Command{ var getApiKeyCmd = &cli.Command{
Name: "get-api-key", Name: "get-api-key",
Usage: "Print API Key", Usage: "Generate API Key",
Action: func(cctx *cli.Context) error { Action: func(cctx *cli.Context) error {
lr, ks, err := openRepo(cctx) lr, ks, err := openRepo(cctx)
if err != nil { if err != nil {
@ -132,6 +143,7 @@ var runCmd = &cli.Command{
Hidden: true, Hidden: true,
}, },
}, },
Description: "For setup instructions see 'lotus-wallet --help'",
Action: func(cctx *cli.Context) error { Action: func(cctx *cli.Context) error {
log.Info("Starting lotus wallet") log.Info("Starting lotus wallet")