Skip to content

Chainbase

Chainbase banner

Chainbase is the world’s largest omnichain data network designed to integrate all blockchain data into a unified ecosystem, providing an open and transparent data interoperability layer for the AI era.

It has designed a novel dual-chain technology architecture that bridges the programmability and composability of crypto data, which supports high throughput, low latency, and eventual determinism, as well as higher cybersecurity through a dual staking model.

ClassvCPUs (10th gen+)MemoryNetworking Capacity
General Purpose - large28 GB5 Mbps
General Purpose - xl416 GB25 Mbps
General Purpose - 4xl1664 GB5 Gbps
1. Update and install packages
Terminal window
sudo apt update & sudo apt upgrade -y
2. Install Docker & Docker compose
Terminal window
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg
echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
sudo apt-get update
sudo apt-get install docker-ce docker-ce-cli containerd.io
docker version
Terminal window
VER=$(curl -s https://api.github.com/repos/docker/compose/releases/latest | grep tag_name | cut -d '"' -f 4)
curl -L "https://github.com/docker/compose/releases/download/"$VER"/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
chmod +x /usr/local/bin/docker-compose
docker-compose --version
3. Install Go
Terminal window
cd $HOME && \
ver="1.22.0" && \
wget "https://golang.org/dl/go$ver.linux-amd64.tar.gz" && \
sudo rm -rf /usr/local/go && \
sudo tar -C /usr/local -xzf "go$ver.linux-amd64.tar.gz" && \
rm "go$ver.linux-amd64.tar.gz" && \
echo "export PATH=$PATH:/usr/local/go/bin:$HOME/go/bin" >> ~/.bash_profile && \
source ~/.bash_profile && \
go version
4. Install EigenLayer CLI
Terminal window
curl -sSfL https://raw.githubusercontent.com/layr-labs/eigenlayer-cli/master/scripts/install.sh | sh -s
export PATH=$PATH:~/bin
eigenlayer --version
5. Clone Chainbase AVS repo
Terminal window
git clone https://github.com/chainbase-labs/chainbase-avs-setup
cd chainbase-avs-setup/holesky
6. Create/Import Eigenlayer wallet
Terminal window
eigenlayer operator keys create --key-type ecdsa "wallet_name"

Set password & save your private key:

banner
# Import an old key (optional)
Terminal window
eigenlayer operator keys import --key-type ecdsa "wallet_name" PRIVATEKEY
7. Fund your Eigen wallet

You’ll need at least 1 Holesky ETH to cover the gas cost of the operator registration.

Link faucet Holesky ETH: https://cloud.google.com/application/web3/faucet/ethereum/holesky
https://holesky-faucet.pk910.de/

8. Config & register operator
Terminal window
eigenlayer operator config create
  • Enter your operator address: your Eigenlayer address
  • Enter your earnings address (default to your operator address): your Eigenlayer address
  • Enter your ETH rpc url: https://ethereum-holesky-rpc.publicnode.com
  • Select your network:
  • Select your signer type:keystore
  • Enter your ecdsa key path: /root/.eigenlayer/operator_keys/joseph-test.ecdsa.key.json
banner
9. Edit metadata.json
Terminal window
nano /root/chainbase-avs-setup/holesky/metadata.json

Sample:

Terminal window
{
"name": "JosephTran",
"website": "https://www.josephtran.xyz",
"description": "Blockchain enthusiast and validator",
"logo": "https://raw.githubusercontent.com/Josephtran102/chainbase/main/Jlogo.png",
"twitter": "https://x.com/josephtran102"
}
  • Create a Public repositry in github
  • Upload logo.png and metadata.jsonthere

Sample: https://github.com/Josephtran102/chainbase

10. Edit operator.yaml
Terminal window
nano /root/chainbase-avs-setup/holesky/operator.yaml

Set URL metadatar with raw file link:

  • metadata url: https://raw.githubusercontent.com/Josephtran102/chainbase/main/metadata.json
banner
11. Register Eigenlayer Operator (holesky)
Terminal window
eigenlayer operator register operator.yaml
banner

Check status:

Terminal window
eigenlayer operator status operator.yaml
banner banner
12. Config Chainbase AVS
a. Create .env file
Terminal window
nano .env

Input content and edit your info:

Terminal window
# Chainbase AVS Image
MAIN_SERVICE_IMAGE=repository.chainbase.com/network/chainbase-node:testnet-v0.1.7
FLINK_TASKMANAGER_IMAGE=flink:latest
FLINK_JOBMANAGER_IMAGE=flink:latest
PROMETHEUS_IMAGE=prom/prometheus:latest
MAIN_SERVICE_NAME=chainbase-node
FLINK_TASKMANAGER_NAME=flink-taskmanager
FLINK_JOBMANAGER_NAME=flink-jobmanager
PROMETHEUS_NAME=prometheus
# FLINK CONFIG
FLINK_CONNECT_ADDRESS=flink-jobmanager
FLINK_JOBMANAGER_PORT=8081
NODE_PROMETHEUS_PORT=9091
PROMETHEUS_CONFIG_PATH=./prometheus.yml
# Chainbase AVS mounted locations
NODE_APP_PORT=8080
NODE_ECDSA_KEY_FILE=/app/operator_keys/ecdsa_key.json
NODE_LOG_DIR=/app/logs
# Node logs configs
NODE_LOG_LEVEL=debug
NODE_LOG_FORMAT=text
# Metrics specific configs
NODE_ENABLE_METRICS=true
NODE_METRICS_PORT=9092
# holesky smart contracts
AVS_CONTRACT_ADDRESS=0x5E78eFF26480A75E06cCdABe88Eb522D4D8e1C9d
AVS_DIR_CONTRACT_ADDRESS=0x055733000064333CaDDbC92763c58BF0192fFeBf
###############################################################################
####### TODO: Operators please update below values for your node ##############
###############################################################################
# TODO: Operators need to point this to a working chain rpc
NODE_CHAIN_RPC=https://rpc.ankr.com/eth_holesky
NODE_CHAIN_ID=17000
# TODO: Operators need to update this to their own paths
USER_HOME=$HOME
EIGENLAYER_HOME=${USER_HOME}/.eigenlayer
CHAINBASE_AVS_HOME=${EIGENLAYER_HOME}/chainbase/holesky
NODE_LOG_PATH_HOST=${CHAINBASE_AVS_HOME}/logs
# TODO: Operators need to update this to their own keys
NODE_ECDSA_KEY_FILE_HOST=${EIGENLAYER_HOME}/operator_keys/joseph-test.ecdsa.key.json
# TODO: Operators need to add password to decrypt the above keys
# If you have some special characters in password, make sure to use single quotes
NODE_ECDSA_KEY_PASSWORD=***123ABCabc123***
  • Update:
b. Edit docker-compose.yml file
Terminal window
nano docker-compose.yml

Sample content: *Replace your key {NODE_ECDSA_KEY_FILE_HOST:-./josephtran.ecdsa.key.json}:${NODE_ECDSA_KEY_FILE}

Terminal window
services:
prometheus:
image: ${PROMETHEUS_IMAGE}
container_name: ${PROMETHEUS_NAME}
env_file:
- .env
volumes:
- "${PROMETHEUS_CONFIG_PATH}:/etc/prometheus/prometheus.yml"
command:
- "--enable-feature=expand-external-labels"
- "--config.file=/etc/prometheus/prometheus.yml"
ports:
- "${NODE_PROMETHEUS_PORT}:9090"
networks:
- chainbase
restart: unless-stopped
flink-jobmanager:
image: ${FLINK_JOBMANAGER_IMAGE}
container_name: ${FLINK_JOBMANAGER_NAME}
env_file:
- .env
command: jobmanager
networks:
- chainbase
restart: unless-stopped
flink-taskmanager:
image: ${FLINK_JOBMANAGER_IMAGE}
container_name: ${FLINK_TASKMANAGER_NAME}
env_file:
- .env
depends_on:
- flink-jobmanager
command: taskmanager
networks:
- chainbase
restart: unless-stopped
chainbase-node:
image: ${MAIN_SERVICE_IMAGE}
container_name: ${MAIN_SERVICE_NAME}
command: ["run"]
env_file:
- .env
ports:
- "${NODE_APP_PORT}:${NODE_APP_PORT}"
- "${NODE_METRICS_PORT}:${NODE_METRICS_PORT}"
volumes:
- "${NODE_ECDSA_KEY_FILE_HOST:-./josephtran.ecdsa.key.json}:${NODE_ECDSA_KEY_FILE}"
- "${NODE_LOG_PATH_HOST}:${NODE_LOG_DIR}:rw"
depends_on:
- prometheus
- flink-jobmanager
- flink-taskmanager
networks:
- chainbase
restart: unless-stopped
networks:
chainbase:
driver: bridge
c. Create folders for docker
Terminal window
source .env && mkdir -pv ${EIGENLAYER_HOME} ${CHAINBASE_AVS_HOME} ${NODE_LOG_PATH_HOST}

Set permissions to bash script chainbase-avs.sh

Terminal window
chmod +x ./chainbase-avs.sh
d. Edit prometheus.yml
Terminal window
nano prometheus.yml

Input your operator address

banner
Terminal window
./chainbase-avs.sh register
banner
Terminal window
./chainbase-avs.sh run
banner
14. Check AVS health
Terminal window
docker compose logs chainbase-node -f
banner
  • Get AVS link
Terminal window
eigenlayer operator status operator.yaml
banner

Check Operator Health

Terminal window
curl -i localhost:8080/eigen/node/health
banner

Check Docker containers

Terminal window
docker ps
banner