Skip to content

Commit

Permalink
chore(holesky): better explanation of operator config steps for EL
Browse files Browse the repository at this point in the history
  • Loading branch information
thedevbirb committed Oct 24, 2024
1 parent ae72386 commit 857260f
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 7 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
{
"rpc": "<hostname>:<port>",
"salt": "0x0000000000000000000_salt_value_0000000000000000000000000000000000",
"expiry": "0x00000000000000000_expiry_value_0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000"
"salt": "0x0000000000000000000_salt_value_000000000000000000000000000000000",
"expiry": "0x00000000000000000_expiry_value_000000000000000000000000000000000"
}

Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ contract RegisterEigenLayerOperator is Script {

BoltEigenLayerMiddlewareV1 middleware = _readMiddleware();
IAVSDirectory avsDirectory = _readAvsDirectory();
OperatorConfig memory config = _readConfig("config/holesky/operator.json");
OperatorConfig memory config = _readConfig("config/holesky/operators/eigenlayer/registerIntoBoltAVS.json");

console.log("Registering EigenLayer operator");
console.log("Operator address:", operator);
Expand Down
33 changes: 30 additions & 3 deletions testnets/holesky/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -563,9 +563,36 @@ forge script script/holesky/operators/RegisterEigenLayerOperator.s.sol \

After having deposited collateral into a strategy you need to register into the
Bolt AVS. We've provided a script to facilitate the procedure. If you want to
use it, please set the operator private key to an `OPERATOR_SK` environment
variable, and then run the following Forge script from the `bolt-contracts`
directory:
use it, please set follow these steps:

1. configure the operator details in this JSON file

```bash
$EDITOR ./config/holesky/operators/eigenlayer/registerIntoBoltAVS.json
```

In there you'll need to set the the following fields:

- `rpc` -- the RPC URL of your operator which supports the Commitments API
- `salt` -- an unique 32 bytes value to avoid replay attacks. To generate it on
both Linux and MacOS you can run:

```bash
echo -n "0x"; head -c 32 /dev/urandom | hexdump -e '32/1 "%02x" "\n"'
```

- `expiry` -- the timestamp of the signature expiry in seconds. To generate it
on both Linux and MacOS run the following command, replacing
`<EXPIRY_TIMESTAMP>` with the desired timestamp:

```bash
echo -n "0x"; printf "%064x\n" <EXPIRY_TIMESTAMP>
```

2. set the operator private key to an `OPERATOR_SK` environment
variable;
3. run the following Forge script from the `bolt-contracts`
directory:

```bash
forge script script/holesky/operators/RegisterEigenLayerOperator.s.sol \
Expand Down

0 comments on commit 857260f

Please sign in to comment.