@bttcnetwork/bttc-cli

0.0.3 • Public • Published

Bttc CLI

🏗 A CLI to setup and manage Bttc validator nodes

Installation

npm install -g @bttcnetwork/bttc-cli

Please make sure you have installed following dependencies:

Usage

Create new directory for the setup:

$ mkdir localnet
$ cd localnet

Check commands

bttc-cli

To setup 1 node local network

This will setup Delivery and Bttc.

bttc-cli setup localnet

It will ask you several questions:

Please enter Bttc chain id - You can keep the default one (15001) or change it to any numeric id
Please enter Delivery chain id - You can keep the default one (Delivery-15001) or change it to a regex (Delivery-<numeric id>)
Please enter Bttc branch or tag - master
Please enter Delivery branch or tag - master
Please enter Contracts branch or tag - Keep the default branch (stake)

After the setup is done, follow these steps:

Start delivery

bash delivery-start.sh

Start delivery bridge

bash delivery-bridge-start.sh

Start delivery rest server

bash delivery-server-start.sh

Setup Bttc

bash bttc-setup.sh

Start bttc

bash bttc-start.sh

To setup multi-node local network

bttc-cli setup devnet

It will ask you several questions:

Please enter Bttc chain id - You can keep the default one (15001) or change it to any numeric id
Please enter delivery chain id - You can keep the default one (delivery-15001) or change it to a regex (delivery-<numeric id>)
Please enter Bttc branch or tag - master
Please enter delivery branch or tag - master
Please enter Contracts branch or tag - Keep the default branch(stake)
Please enter number of validator nodes - Input the number of validator nodes you want to run
Please enter number of non-validator nodes - Input the number of sentry nodes you want to run
Please enter ETH url - http://ganache:9545
Please select devnet type - docker (for docker setup)

After the setup is done, follow these steps:

Start all delivery instances (it will run all services - rabbitmq, delivery, bridge, server)

bash docker-delivery-start-all.sh

Setup bttc

bash docker-bttc-setup.sh

Start bttc

bash docker-bttc-start-all.sh

Logs

Logs will be at logs/ folder

SSH to docker containers through tmux

For delivery

bash docker-delivery-tmux.sh

For bttc

bash docker-bttc-tmux.sh

Clean Setup Remove the localnet folder and you can start the process once again

License

MIT

Readme

Keywords

Package Sidebar

Install

npm i @bttcnetwork/bttc-cli

Weekly Downloads

1

Version

0.0.3

License

MIT

Unpacked Size

76.5 kB

Total Files

35

Last publish

Collaborators

  • bttcnetwork