Browse Source

Add minimum documentation of serveapi command

feature/fastsync-skip-updateeth
Eduard S 3 years ago
parent
commit
8c51cfb3d2
1 changed files with 13 additions and 0 deletions
  1. +13
    -0
      cli/node/README.md

+ 13
- 0
cli/node/README.md

@ -24,6 +24,7 @@ COMMANDS:
genbjj Generate a new BabyJubJub key
wipesql Wipe the SQL DB (HistoryDB and L2DB) and the StateDBs, leaving the DB in a clean state
run Run the hermez-node in the indicated mode
serveapi Serve the API only
discard Discard blocks up to a specified block number
help, h Shows a list of commands or help for one command
@ -54,6 +55,10 @@ To read the documentation of each configuration parameter, please check the
with `Coordinator` are only used in coord mode, and don't need to be defined
when running the coordinator in sync mode
When running the API in standalone mode, the required configuration is a subset
of the node configuration. Please, check the `type APIServer` at
[config/config.go](../../config/config.go) to learn about all the parametes.
### Notes
- The private key corresponding to the parameter `Coordinator.ForgerAddress` needs to be imported in the ethereum keystore
@ -107,6 +112,14 @@ Run the node in mode coordinator:
./node run --mode coord --cfg cfg.buidler.toml
```
Serve the API in standalone mode. This command allows serving the API just
with access to the PostgreSQL database that a node is using. Several instances
of `serveapi` can be running at the same time with a single PostgreSQL
database:
```shell
./node serveapi --mode coord --cfg cfg.buidler.toml
```
Import an ethereum private key into the keystore:
```shell
./node importkey --mode coord --cfg cfg.buidler.toml --privatekey 0x618b35096c477aab18b11a752be619f0023a539bb02dd6c813477a6211916cde

Loading…
Cancel
Save