|
| 1 | +# Pausable |
| 2 | +This doc contains a guide on how to call `setAggregator(address)` to set the `alignedAggregator` value of the AlignedServiceManager.sol contract. |
| 3 | + |
| 4 | +### NOTE: |
| 5 | +- This guide assumes the Aligned layer contracts have been sucessfully deployed and the deployment outputs are within `./contracts/script/output/<DEPLOYMENT_FOLDER> |
| 6 | + |
| 7 | +## Locate the deployed Aligned Aggregator Address |
| 8 | + |
| 9 | +The address of Aligned Aggregator can be found in `./contracts/script/output/<DEPLOYMENT_FOLDER>/aligned_deployment_output.json` within |
| 10 | +``` |
| 11 | + "permissions": { |
| 12 | + ... |
| 13 | + "alignedLayerAggregator": "<AGGREGATOR_ADDRESS", |
| 14 | + ... |
| 15 | + } |
| 16 | +``` |
| 17 | + |
| 18 | +## Locate the Aligend Service Manager Address |
| 19 | + |
| 20 | +The address of Aligned Service Manager can be found in `./contracts/script/output/<DEPLOYMENT_FOLDER>/aligned_deployment_output.json` within |
| 21 | +``` |
| 22 | + "addresses": { |
| 23 | + ... |
| 24 | + "alignedLayerServiceManager": "<ALIGNED_SERVICE_MANAGER_ADDRESS", |
| 25 | + ... |
| 26 | + } |
| 27 | +``` |
| 28 | + |
| 29 | +## Set Environment Variables |
| 30 | + |
| 31 | +To run the make targets specified in this guide, you must first set the following env vars within `./contracts/scripts/.env`: |
| 32 | +``` |
| 33 | +export RPC_URL=<rpc_url> |
| 34 | +export PRIVATE_KEY=<aligned_service_manager_pauser_private_key> |
| 35 | +export ALIGNED_SERVICE_MANAGER_ADDRESS=<aligned_service_manager_address> |
| 36 | +``` |
| 37 | + |
| 38 | +## Check the current value of `alignedAggregator` within AlignedServiceManager.sol |
| 39 | + |
| 40 | +``` |
| 41 | +cast call $ALIGNED_SERVICE_MANAGER_ADDRESS "alignedAggregator()(address)" |
| 42 | +``` |
| 43 | + |
| 44 | +You should see that the printed address matches the returned address matches the address from `./contracts/script/output/<DEPLOYMENT_FOLDER>/aligned_deployment_output.json` |
| 45 | + |
| 46 | +## Change the value of `alignedAggregator` within AlignedServiceManager.sol |
| 47 | + |
| 48 | +Set the environment variable `AGGREGATOR_ADDRESS` to the new address of the aggregator. |
| 49 | +``` |
| 50 | +export AGGREGATOR_ADDRESS=<aggregator_address> |
| 51 | +make set_aggregator_address |
| 52 | +``` |
| 53 | + |
| 54 | +## Verify the Aligend Aggreagtor Address has changed |
| 55 | +``` |
| 56 | +cast call $ALIGNED_SERVICE_MANAGER_ADDRESS "alignedAggregator()(address)" |
| 57 | +``` |
| 58 | + |
| 59 | +You should observe that the printed address matches the address in `AGGREGATOR_ADDRESS`. |
0 commit comments