datahaven/test/cli/handlers/contracts/README.md
undercover-cactus 863250d555
misc: remove slasher middleware solidity contracts (#366)
## Summary

This PR remove the middlewares contracts from eigen layer. Instead we
are planning to use the eigne layer contract directly. It also removes
the tests related to the middleware slasher code and the mock contract
used in it.

## Motivation

When slashing an operator in the Dathaven we are going through the
substrate slashing pallet already implemented. It already allow to
configure a slashing window and/or to cancel a slashing. In the future
it will also be compatible with a government pallet. This part of code
is therefore redundant. For the same reason we remove the tests because
we are not using the slashing middleware contracts.

## What changed

* Remove the slasher middleware files
* Remove the tests related to the middleware slasher file
2025-12-29 14:55:21 +01:00

1.7 KiB

DataHaven Contracts Deployment

Deploy DataHaven AVS contracts to supported chains (Hoodi, Mainnet).

What Gets Deployed

  • DataHaven: ServiceManager, RewardsRegistry
  • Snowbridge: BeefyClient, AgentExecutor, Gateway, RewardsAgent
  • EigenLayer: References existing contracts (not deployed)

Prerequisites

  1. Account Setup: Create or import an account in Metamask (you'll need the private key)
  2. Funding: Get native tokens for deployment fees:
  3. API Key (optional): Generate API token from block explorer for contract verification:

Setup

cd test && cp cli/handlers/contracts/.env.example .env

Edit .env with your values:

# Required: Private key with deployment funds
DEPLOYER_PRIVATE_KEY=0x...

# Required: AVS owner private key (can be same as DEPLOYER_PRIVATE_KEY)
AVS_OWNER_PRIVATE_KEY=0x...

# Optional: For contract verification
ETHERSCAN_API_KEY=your_api_key_here

Deployment Commands

Deploy to Hoodi

bun cli contracts deploy --chain hoodi

Deploy to Mainnet

bun cli contracts deploy --chain mainnet

Custom RPC URL

bun cli contracts deploy --chain hoodi --rpc-url https://your-rpc-url.com

Check Deployment Status

bun cli contracts status --chain hoodi

Deployment Files

Successful deployments create:

  • ../contracts/deployments/{chain}.json - Contract addresses
  • ../contracts/deployments/{chain}-rewards-info.json - Rewards configuration