-
Notifications
You must be signed in to change notification settings - Fork 741
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Validator manager commands for the Keymanager APIs (#6261)
* Validator manager commands for standard key-manager APIs * Merge latest unstable * Fix Some in lib.rs * Replace Arg::with_name with Arg::new * Update takes_value * Remove clap::App * Change App to Command * Add command in use * Remove generic in ArgMatches * Fix matches.get_flag * Fixes * fix error handling * SetTrue in import * Fix * Fix builder-proposal flag (will delete the flag later) * Minor fix * Fix prefer_builder_proposals * Remove unwrap * Error handling from Michael * Add cli help text * Use None in import to simplify * Delete unwrap * Revert flags option * Simplify help command code * Remove flag header in move * Merge remote-tracking branch 'origin/unstable' into pahor/validator-manager-standard-keystore * Add log in VC when keystore is deleted * Delete duplicated log when validator does not exist * Simplify log code * Rename remove to delete * cargo-fmt * Try to remove a function * make-cli * Error handling * Merge branch 'vm' of https://github.com/chong-he/lighthouse into vm * Update CLI hel text * make-cli * Fix checks * Merge branch 'vm' of https://github.com/chong-he/lighthouse into vm * Try to fix check errors * Fix test * Remove changes * Update flag name * CLI display order * Move builde_proposals flag * Add doc * mdlint * Update validator_manager/src/list_validators.rs Co-authored-by: Mac L <mjladson@pm.me> * Delete empty line * Fix list * Simplify delete * Add support to delete more validators * Fix test * Rename response * Add (s) * Add test to delete multiple validators * Book and cli * Make cli * Only log when keystore is deleted * Revise deletion log * Add validator pubkey to error message * Merge import * Thank you Mac * Test * Add flags * Error handling for password * make cli * Merge remote-tracking branch 'origin/unstable' into vm * make cli * Fix test * Merge branch 'vm' of https://github.com/chong-he/lighthouse into vm * Fix test * vm test * Debug trait thank you Michael * Fix test * Merge branch 'unstable' into vm * test * testing * Combine import validator(s) * make cli * Add requires * Update book * mdlint * Only show import log when import is successful * delete testing * Test for standard format * Test standard format * Test * fix builder_proposals flag * Fix test for standard format * Add requires * Fix vm test * make cli * Remove flag header * Merge branch 'vm' of https://github.com/chong-he/lighthouse into vm * make cli * Delete space * Merge branch 'vm' of https://github.com/chong-he/lighthouse into vm * Merge branch 'unstable' into vm * Rename delete_validator to delete_validators * Rearrange * Remove pub in run function * Fix grammar * Apply suggestions from code review Co-authored-by: Michael Sproul <micsproul@gmail.com> * Remove description * Merge branch 'vm' of https://github.com/chong-he/lighthouse into vm * Close bracket * make cli * Revise list code and test * Revise import flag * make cli * Comment out test * Update vm test * Simplify * Merge remote-tracking branch 'origin/unstable' into vm * make cli * Add test * Add password as a requirement for keystore file * Correct flags in docs * typo
- Loading branch information
Showing
16 changed files
with
1,031 additions
and
73 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
# Managing Validators | ||
|
||
The `lighthouse validator-manager` uses the [Keymanager API](https://ethereum.github.io/keymanager-APIs/#/) to list, import and delete keystores via the HTTP API. This requires the validator client running with the flag `--http`. | ||
|
||
## Delete | ||
|
||
The `delete` command deletes one or more validators from the validator client. It will also modify the `validator_definitions.yml` file automatically so there is no manual action required from the user after the delete. To `delete`: | ||
|
||
```bash | ||
lighthouse vm delete --vc-token <API-TOKEN-PATH> --validators pubkey1,pubkey2 | ||
``` | ||
|
||
Example: | ||
|
||
```bash | ||
lighthouse vm delete --vc-token ~/.lighthouse/mainnet/validators/api-token.txt --validators 0x8885c29b8f88ee9b9a37b480fd4384fed74bda33d85bc8171a904847e65688b6c9bb4362d6597fd30109fb2def6c3ae4,0xa262dae3dcd2b2e280af534effa16bedb27c06f2959e114d53bd2a248ca324a018dc73179899a066149471a94a1bc92f | ||
``` | ||
|
||
## Import | ||
|
||
The `import` command imports validator keystores generated by the staking-deposit-cli/ethstaker-deposit-cli. To import a validator keystore: | ||
|
||
```bash | ||
lighthouse vm import --vc-token <API-TOKEN-PATH> --keystore-file /path/to/json --password keystore_password | ||
``` | ||
|
||
Example: | ||
|
||
``` | ||
lighthouse vm import --vc-token ~/.lighthouse/mainnet/validators/api-token.txt --keystore-file keystore.json --password keystore_password | ||
``` | ||
|
||
## List | ||
|
||
To list the validators running on the validator client: | ||
|
||
```bash | ||
lighthouse vm list --vc-token ~/.lighthouse/mainnet/validators/api-token.txt | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.