Files
proxmox/scripts/health-check.sh
defiQUG fbda1b4beb
Some checks failed
Deploy to Phoenix / deploy (push) Has been cancelled
docs: Ledger Live integration, contract deploy learnings, NEXT_STEPS updates
- ADD_CHAIN138_TO_LEDGER_LIVE: Ledger form done; public code review repo bis-innovations/LedgerLive; init/push commands
- CONTRACT_DEPLOYMENT_RUNBOOK: Chain 138 gas price 1 gwei, 36-addr check, TransactionMirror workaround
- CONTRACT_*: AddressMapper, MirrorManager deployed 2026-02-12; 36-address on-chain check
- NEXT_STEPS_FOR_YOU: Ledger done; steps completable now (no LAN); run-completable-tasks-from-anywhere
- MASTER_INDEX, OPERATOR_OPTIONAL, SMART_CONTRACTS_INVENTORY_SIMPLE: updates
- LEDGER_BLOCKCHAIN_INTEGRATION_COMPLETE: bis-innovations/LedgerLive reference

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-12 15:46:57 -08:00

66 lines
1.9 KiB
Bash
Executable File

#!/usr/bin/env bash
set -euo pipefail
# Load IP configuration
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
PROJECT_ROOT="$(cd "$SCRIPT_DIR/.." && pwd)"
source "${PROJECT_ROOT}/config/ip-addresses.conf" 2>/dev/null || true
# Comprehensive health check for bridge system
source /home/intlc/projects/smom-dbis-138/.env
RPC_URL="${RPC_URL_138_PUBLIC:-http://${RPC_PUBLIC_1:-192.168.11.221}:8545}"
echo "=== Bridge System Health Check ==="
echo ""
# Check RPC connectivity
echo "1. RPC Connectivity:"
if cast block-number --rpc-url "$RPC_URL" >/dev/null 2>&1; then
echo " ✅ RPC is accessible"
else
echo " ❌ RPC is not accessible"
fi
# Check bridge contracts
echo ""
echo "2. Bridge Contracts:"
WETH9_BRIDGE="${CCIPWETH9_BRIDGE_CHAIN138:-0x971cD9D156f193df8051E48043C476e53ECd4693}"
WETH10_BRIDGE="0xe0E93247376aa097dB308B92e6Ba36bA015535D0"
if cast code "$WETH9_BRIDGE" --rpc-url "$RPC_URL" >/dev/null 2>&1; then
echo " ✅ WETH9 Bridge deployed"
else
echo " ❌ WETH9 Bridge not found"
fi
if cast code "$WETH10_BRIDGE" --rpc-url "$RPC_URL" >/dev/null 2>&1; then
echo " ✅ WETH10 Bridge deployed"
else
echo " ❌ WETH10 Bridge not found"
fi
# Check destination chains
echo ""
echo "3. Destination Chains:"
declare -A CHAINS=(
["BSC"]="11344663589394136015"
["Polygon"]="4051577828743386545"
["Avalanche"]="6433500567565415381"
["Base"]="15971525489660198786"
["Arbitrum"]="4949039107694359620"
["Optimism"]="3734403246176062136"
["Ethereum"]="5009297550715157269"
)
for chain in "${!CHAINS[@]}"; do
selector="${CHAINS[$chain]}"
result=$(cast call "$WETH9_BRIDGE" "destinations(uint64)" "$selector" --rpc-url "$RPC_URL" 2>/dev/null || echo "")
if [ -n "$result" ] && ! echo "$result" | grep -q "0x0000000000000000000000000000000000000000$"; then
echo "$chain configured"
else
echo "$chain not configured"
fi
done