Skip to content

thienngho/bsc-node-lb-healthcheck

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

53 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

bsc-node-lb-healthcheck

Little http node.js server to run along the bsc node. Node needs to have JSONRPC enabled. Returns 500 if the last block number on the local node is off by 3 or more blocks from the last block number from Infura node. Otherwise returns 200.

Supported networks:

  • homestead
  • rinkeby
  • ropsten
  • kovan
  • goerli

Installation

npm install -g @thienngho/bsc-node-lb-healthcheck

Run

Configuration parameters (set as variables in .env file):

  • ETH_RPC_HOST — hostname where your node JSON RPC is running. Default: localhost

  • ETH_NETWORK — network name. Supported networks:

    • homestead
    • rinkeby
    • ropsten
    • kovan
    • goerli
  • ETH_MONITOR_PORT — port to run this service on

  • ETH_PORT - RPC port of JSON RPC service

Make sure the process is detached from the terminal. Make sure the port is open for incoming connections.

License

MIT

About

Geth/Parity node healthcheck endpoint. Check the node is in sync with the network

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 92.5%
  • Shell 7.5%