160 lines
5.4 KiB
YAML
160 lines
5.4 KiB
YAML
# MEV Bot Staging Environment Configuration
|
|
# This configuration is for testing in a production-like environment with reduced risk
|
|
|
|
# Arbitrum node configuration
|
|
arbitrum:
|
|
# RPC endpoint for Arbitrum node (using premium provider for staging)
|
|
rpc_endpoint: "${ARBITRUM_RPC_ENDPOINT}"
|
|
# WebSocket endpoint for Arbitrum node (optional)
|
|
ws_endpoint: "${ARBITRUM_WS_ENDPOINT}"
|
|
# Chain ID for Arbitrum (42161 for mainnet)
|
|
chain_id: 42161
|
|
# Rate limiting configuration for RPC endpoint (more conservative than production)
|
|
rate_limit:
|
|
# Maximum requests per second (reduced to avoid hitting limits)
|
|
requests_per_second: 50
|
|
# Maximum concurrent requests (reduced to avoid overload)
|
|
max_concurrent: 5
|
|
# Burst size for rate limiting
|
|
burst: 100
|
|
# Fallback RPC endpoints
|
|
fallback_endpoints:
|
|
- url: "https://arb1.arbitrum.io/rpc"
|
|
rate_limit:
|
|
requests_per_second: 25
|
|
max_concurrent: 3
|
|
burst: 50
|
|
- url: "https://arbitrum.llamarpc.com"
|
|
rate_limit:
|
|
requests_per_second: 30
|
|
max_concurrent: 3
|
|
burst: 60
|
|
- url: "https://arbitrum-one.publicnode.com"
|
|
rate_limit:
|
|
requests_per_second: 20
|
|
max_concurrent: 2
|
|
burst: 40
|
|
|
|
# Bot configuration
|
|
bot:
|
|
# Enable or disable the bot
|
|
enabled: true
|
|
# Polling interval in seconds (slower than production for testing)
|
|
polling_interval: 10
|
|
# Minimum profit threshold in USD (higher than production for testing)
|
|
min_profit_threshold: 50.0
|
|
# Gas price multiplier (for faster transactions)
|
|
gas_price_multiplier: 1.2
|
|
# Maximum number of concurrent workers for processing (reduced for staging)
|
|
max_workers: 3
|
|
# Buffer size for channels
|
|
channel_buffer_size: 100
|
|
# Timeout for RPC calls in seconds
|
|
rpc_timeout: 30
|
|
|
|
# Uniswap configuration
|
|
uniswap:
|
|
# Factory contract address
|
|
factory_address: "0x1F98431c8aD98523631AE4a59f267346ea31F984"
|
|
# Position manager contract address
|
|
position_manager_address: "0xC36442b4a4522E871399CD717aBDD847Ab11FE88"
|
|
# Supported fee tiers
|
|
fee_tiers:
|
|
- 500 # 0.05%
|
|
- 3000 # 0.3%
|
|
- 10000 # 1%
|
|
# Cache configuration for pool data
|
|
cache:
|
|
# Enable or disable caching
|
|
enabled: true
|
|
# Cache expiration time in seconds
|
|
expiration: 300
|
|
# Maximum cache size
|
|
max_size: 5000
|
|
|
|
# Logging configuration
|
|
log:
|
|
# Log level (debug, info, warn, error)
|
|
level: "debug"
|
|
# Log format (json, text)
|
|
format: "text"
|
|
# Log file path (empty for stdout)
|
|
file: "logs/mev-bot_staging.log"
|
|
|
|
# Database configuration
|
|
database:
|
|
# Database file path
|
|
file: "data/mev-bot_staging.db"
|
|
# Maximum number of open connections
|
|
max_open_connections: 10
|
|
# Maximum number of idle connections
|
|
max_idle_connections: 5
|
|
|
|
# Ethereum configuration
|
|
ethereum:
|
|
# Private key for transaction signing (NEVER COMMIT TO VERSION CONTROL)
|
|
private_key: "${ETHEREUM_PRIVATE_KEY}"
|
|
# Account address
|
|
account_address: "${ETHEREUM_ACCOUNT_ADDRESS}"
|
|
# Gas price multiplier (for faster transactions)
|
|
gas_price_multiplier: 1.2
|
|
|
|
# Smart contract addresses
|
|
contracts:
|
|
# Arbitrage executor contract address
|
|
arbitrage_executor: "${CONTRACT_ARBITRAGE_EXECUTOR}"
|
|
# Flash swapper contract address
|
|
flash_swapper: "${CONTRACT_FLASH_SWAPPER}"
|
|
# Authorized caller addresses
|
|
authorized_callers:
|
|
- "${ETHEREUM_ACCOUNT_ADDRESS}"
|
|
# Authorized DEX addresses
|
|
authorized_dexes:
|
|
- "0x1F98431c8aD98523631AE4a59f267346ea31F984" # Uniswap V3
|
|
- "0xf1D7CC64Fb4452F05c498126312eBE29f30Fbcf9" # Uniswap V2
|
|
- "0xc35DADB65012eC5796536bD9864eD8773aBc74C4" # SushiSwap V2
|
|
- "0x6EcCab422D763aC031210895C81787E87B82A80f" # Camelot V2
|
|
- "0xaE4EC9901c3076D0DdBe76A520F9E90a6227aCB7" # TraderJoe
|
|
- "0xBA12222222228d8Ba445958a75a0704d566BF2C8" # Balancer V2
|
|
- "0x445FE580eF8d70FF569aB36e80c647af338db351" # Curve
|
|
|
|
# Arbitrage configuration
|
|
arbitrage:
|
|
# Enable or disable arbitrage service
|
|
enabled: true
|
|
# Contract addresses
|
|
arbitrage_contract_address: "${CONTRACT_ARBITRAGE_EXECUTOR}"
|
|
flash_swap_contract_address: "${CONTRACT_FLASH_SWAPPER}"
|
|
# Profitability settings
|
|
min_profit_wei: 50000000000000000 # 0.05 ETH minimum profit
|
|
min_roi_percent: 2.0 # 2% minimum ROI
|
|
min_significant_swap_size: 100000000000000000 # 0.1 ETH minimum swap size
|
|
slippage_tolerance: 0.01 # 1% slippage tolerance
|
|
# Scanning configuration
|
|
min_scan_amount_wei: 10000000000000000 # 0.01 ETH minimum scan amount
|
|
max_scan_amount_wei: 1000000000000000000 # 1 ETH maximum scan amount
|
|
# Gas configuration
|
|
max_gas_price_wei: 50000000000 # 50 gwei max gas price
|
|
# Execution limits
|
|
max_concurrent_executions: 2
|
|
max_opportunities_per_event: 3
|
|
# Timing settings
|
|
opportunity_ttl: 30s
|
|
max_path_age: 60s
|
|
stats_update_interval: 10s
|
|
# Pool discovery configuration
|
|
pool_discovery_config:
|
|
enabled: true
|
|
block_range: 1000
|
|
polling_interval: 30s
|
|
factory_addresses:
|
|
- "0x1F98431c8aD98523631AE4a59f267346ea31F984" # Uniswap V3
|
|
- "0xf1D7CC64Fb4452F05c498126312eBE29f30Fbcf9" # Uniswap V2
|
|
- "0xc35DADB65012eC5796536bD9864eD8773aBc74C4" # SushiSwap V2
|
|
- "0x6EcCab422D763aC031210895C81787E87B82A80f" # Camelot V2
|
|
- "0xaE4EC9901c3076D0DdBe76A520F9E90a6227aCB7" # TraderJoe
|
|
- "0xBA12222222228d8Ba445958a75a0704d566BF2C8" # Balancer V2
|
|
- "0x445FE580eF8d70FF569aB36e80c647af338db351" # Curve
|
|
min_liquidity_wei: 1000000000000000000 # 1 ETH minimum liquidity
|
|
cache_size: 10000
|
|
cache_ttl: 1h |