Sign inSign up

reddev2020/redbridge-oracle-node

By reddev2020

•Updated 5 days ago

An oracle that bridges Zcash block data onto an Avalanche L1.

Image
Integration & delivery
0

1.1K

reddev2020/redbridge-oracle-node repository overview

⁠ZavaX Oracle Node

AvalancheGo v1.14.0 + the redbridge-oracle custom Snowman VM plugin (bridges Zcash block data onto an Avalanche L1 via Warp messaging), pre-baked into the official avaplatform/avalanchego image.

  • VM name: redbridge
  • VM ID: sP6SrkPy8HGHCqRwuxuvCPPUKSxLX5hZtozvNPQxFsLfAZgiT
  • Plugin binary is already installed at the correct path — no manual plugin setup needed.

Two image tags are published, differing only in which AVAGO_NETWORK_ID is baked in as the default:

  • v1.0.0-fuji — defaults to Fuji testnet. Use this one — it's a ready-to-run deployment.
  • v1.0.0 — defaults to mainnet, but AVAGO_TRACK_SUBNETS/ZAVAX_CHAIN_ID are still the Fuji Avalanche L1/chain IDs (redbridge-oracle isn't deployed to mainnet yet). Not usable as-is — see "Environment variables" below before reaching for it.

⁠Prerequisites

MinimumRecommended
CPU8 vCPU16 vCPU
RAM16 GB32 GB
Storage1 TB NVMe SSD2 TB NVMe SSD
Network200 Mbps, static/reserved public IP1 Gbps

⁠Quick start

docker pull reddev2020/redbridge-oracle-node:v1.0.0-fuji
docker run -d --name redbridge-oracle \
  -p 9651:9651 \
  -p 127.0.0.1:9650:9650 \
  -v redbridge-data:/root/.avalanchego \
  --restart unless-stopped \
  reddev2020/redbridge-oracle-node:v1.0.0-fuji

That's a complete Fuji-testnet node — network ID, tracked Avalanche L1, and chain config all come from defaults baked into the image. The only things you had to pass are the two ports (never baked in, regardless of tag) and a volume for persistence.

Want a real Zcash data source instead of the 127.0.0.1:8232 default?

docker run -d --name redbridge-oracle \
  -e ZCASH_RPC_ENDPOINT=http://your-zebra-host:8232 \
  -e ZCASH_RPC_USER=<rpc_user> \
  -e ZCASH_RPC_PASSWORD=<rpc_password> \
  -p 9651:9651 \
  -p 127.0.0.1:9650:9650 \
  -v redbridge-data:/root/.avalanchego \
  --restart unless-stopped \
  reddev2020/redbridge-oracle-node:v1.0.0-fuji

If you override AVAGO_HTTP_PORT/AVAGO_STAKING_PORT from their defaults, update both the -e value and the matching -p mapping — the two are independent flags and Docker won't reconcile them for you.

⁠Ports

PortPurposePublish policy
9650AvalancheGo HTTP RPC (VM served under /ext/bc/<chainID>/rpc)Do not expose publicly. Bind to 127.0.0.1 (as in the quick start above) and put a reverse proxy in front for production.
9651AvalancheGo P2P / stakingMust be reachable from the internet for validators.

⁠Environment variables

AvalancheGo reads any CLI flag as --flag-name -> AVAGO_FLAG_NAME (dashes -> underscores, uppercased) — any flag from the AvalancheGo config reference (https://docs.avax.network/nodes/configure/configs-flags⁠) works this way, not just the ones below.

VariablePurposeDefault
AVAGO_NETWORK_IDNetwork to join: fuji, mainnet, or a numeric local IDBaked into the image tag — fuji for *-fuji tags, mainnet otherwise. Override with -e to change it at runtime.
AVAGO_HTTP_HOSTRPC bind address inside the container0.0.0.0 (rebind to 127.0.0.1 on the host via -p 127.0.0.1:PORT:PORT, as above — don't change this variable itself)
AVAGO_HTTP_PORTAvalancheGo RPC port9650
AVAGO_STAKING_PORTAvalancheGo P2P/staking port9651
AVAGO_TRACK_SUBNETSAvalanche L1 ID(s) this node tracks/validatesFuji redbridge-oracle Avalanche L1
ZAVAX_CHAIN_IDBlockchain ID whose VM config.json to generateFuji redbridge-oracle chain
ZCASH_RPC_ENDPOINTZcash JSON-RPC URLhttp://127.0.0.1:8232
ZCASH_RPC_USERZcash RPC username(empty)
ZCASH_RPC_PASSWORDZcash RPC password(empty)
ZCASH_CONFIRMATION_DEPTHConfirmations required before a height can be bridged24

The entrypoint writes the ZCASH_* values into $AVAGO_DATA_DIR/configs/chains/$ZAVAX_CHAIN_ID/config.json before starting AvalancheGo. If you'd rather manage that file yourself, leave ZAVAX_CHAIN_ID unset and mount your own config.json into the volume.

Switching networks: AVAGO_TRACK_SUBNETS and ZAVAX_CHAIN_ID above are the Fuji Avalanche L1/chain IDs — they won't resolve on mainnet. If/when redbridge-oracle is deployed to mainnet, override all three (AVAGO_NETWORK_ID, AVAGO_TRACK_SUBNETS, ZAVAX_CHAIN_ID) together — don't just flip AVAGO_NETWORK_ID on its own — and start from a fresh volume: a data dir bootstrapped against Fuji genesis can't be reused for mainnet.

⁠Persistence

/root/.avalanchego is the AvalancheGo data directory — staking keys, DB, chain/Avalanche L1 configs all live there. Always mount a volume:

-v redbridge-data:/root/.avalanchego

(or a host bind-mount, e.g. -v /mnt/blockstorage/.avalanchego-node1:/root/.avalanchego).

Back up <data-dir>/staking (staker.key + signer.key) — losing it means losing the validator's NodeID and having to re-onboard as a validator.

To reuse an existing (non-Docker) AvalancheGo data directory, stop that process first (a DB can't be held open by two processes at once), then bind-mount it in directly — the container will pick up the same NodeID and state.

⁠Verify it's running

# Primary Network bootstrapped
curl -s -X POST --data '{"jsonrpc":"2.0","id":1,"method":"info.isBootstrapped","params":{"chain":"P"}}' \
  -H 'content-type:application/json' http://127.0.0.1:9650/ext/info

# redbridge-oracle chain bootstrapped
curl -s -X POST --data '{"jsonrpc":"2.0","id":1,"method":"info.isBootstrapped","params":{"chain":"2TrCrta1d2vgipS4okDzybWk42qTDFmACQ2Jyx3pgKdxqhDJSJ"}}' \
  -H 'content-type:application/json' http://127.0.0.1:9650/ext/info

# redbridge-oracle chain serving VM RPC
curl -s -X POST --data '{"jsonrpc":"2.0","id":1,"method":"zavax.getBlockByHeight","params":{"height":100}}' \
  -H 'content-type:application/json' \
  http://127.0.0.1:9650/ext/bc/2TrCrta1d2vgipS4okDzybWk42qTDFmACQ2Jyx3pgKdxqhDJSJ/rpc

⁠Post-install checklist

  • info.isBootstrapped returns true for chain P
  • info.isBootstrapped returns true for the redbridge-oracle blockchain ID
  • NodeID and staking cert (staker.key + signer.key) backed up
  • HTTP RPC port (9650) is not reachable from the public internet
  • Staking port (9651) is reachable from the public internet
  • AVAGO_TRACK_SUBNETS includes the redbridge-oracle Avalanche L1 ID

Tag summary

Content type

Image

Digest

sha256:374a61706…

Size

91.4 MB

Last updated

5 days ago

docker pull reddev2020/redbridge-oracle-node:v1.0.0-fuji