Quick Start

A guide to start REI Network Node

Install

Install from npm:

npm install @rei-network/cli --global

Install from source code:

git clone https://github.com/rei-network/rei.git
cd rei
npm install
npm link -w @rei-network/cli

Usage

Usage: rei [options] [command]

Options:
  -V, --version                              output the version number
  --rpc                                      open rpc server
  --rpc-port <port>                          rpc server port
  --rpc-host <port>                          rpc server host
  --rpc-api <apis>                           rpc server apis: debug, eth, net, txpool, web3
  --disable-p2p                              disable p2p server
  --p2p-tcp-port <port>                      p2p server tcp port
  --p2p-udp-port <port>                      p2p server udp port
  --p2p-nat <ip>                             p2p server nat ip
  --max-peers <peers>                        max p2p peers count
  --max-dials <dials>                        max p2p dials count
  --bootnodes <bootnodes...>                 comma separated list of bootnodes
  --datadir <path>                           chain data dir path (default: "~/.rei")
  --keystore <keystore>                      the datadir for keystore (default: "keystore")
  --unlock <unlock>                          comma separated list of accounts to unlock
  --password <password>                      password file to use for non-interactive password input
  --chain <chain>                            chain name: rei-mainnet, rei-testnet, rei-devnet
  --mine                                     mine block
  --coinbase <address>                       miner address
  --verbosity <verbosity>                    logging verbosity: silent, error, warn, info, debug, detail (default: "info")
  --receipts-cache-size <receiptsCacheSize>  receipts cache size
  -h, --help                                 display help for command

Commands:
  account                                    Manage accounts

Default settings:

Example

Proposer node startup

rei --mine --coinbase 0x...abc --unlock 0x...abc --password ./password

RPC node startup

rei --rpc --rpc-host 0.0.0.0

Bootnode startup

rei --p2p-nat 1.2.3.4

Testnet or devnet node startup

rei --chain rei-testnet
rei --chain rei-devnet

Last updated