Quick start
Requirements
- A Zcash validator with JSON-RPC enabled: Zebra
(
zebrad, tested with 6.2.3) or Zakura (zakurad). Set[rpc] listen_addrin its config. - Local storage for the indexes, preferably NVMe (first sync).
Zingod uses these Zcash JSON-RPC methods: getblock,
getblockchaininfo, getblockhash, getblockheader, getdeprecationinfo, getinfo,
getpeerinfo, getrawmempool, getrawtransaction and sendrawtransaction. If the validator
restricts its RPC methods, allow these. Zingod also calls checkadmission when the validator
supports it.
Run with Docker
-
Generate a config with every key at its default:
docker run --rm zingodevops/zingod generate-config -o /dev/stdout > zingod.toml -
Edit
zingod.toml:- Set
networktomainnet,testnetorregtest. - Set
jsonrpc_addressunder[[trusted_validators]]to your validator. - Set
tlsunder[serve]. The container listens on all interfaces, so Zingod requires it:tls = "off"if wallets connect only from this host, or a certificate pair (TLS).
- Set
-
Start it:
docker run -d --name zingod -p 127.0.0.1:8137:8137 \ -v ./zingod.toml:/etc/zingod/zingod.toml:ro \ -v zingod-data:/var/lib/zingod \ zingodevops/zingod -
Wait for the first sync. It takes about an hour on NVMe with the validator on the same host, and longer over a network. An index snapshot skips most of it. Check progress over HTTP on the gRPC port:
curl -s http://localhost:8137/status # state and tip curl -sf http://localhost:8137/readyz && echo serving # 200 once ready
Wallets can then connect to http://localhost:8137. See Docker for volumes, TLS
mounts and Compose.
Run on a host
Building requires protoc on PATH.
cargo install --locked --git https://github.com/zingolabs/zingod zingod
zingod generate-config # writes $XDG_CONFIG_HOME/zingod/zingod.toml
zingod start # or: zingod start -c /path/to/zingod.toml
Run it under a service manager such as systemd. zingod --help lists
every subcommand.
Try it on the Public Testnet
zebrad.toml and zingod.toml are a matching pair of configs for
the Public Testnet, with zebrad’s JSON-RPC on 127.0.0.1:18232.
- Install zebrad:
cargo install zebrad --locked. - In
zebrad.toml, replace<PATH_TO_ZEBRA>with a writable directory. Inzingod.toml, replace<ZINGOD_DATA>. - Run
zebrad -c zebrad.toml start. - In another shell, run
zingod start -c zingod.toml.
Zingod serves gRPC on 127.0.0.1:8137.