-
Notifications
You must be signed in to change notification settings - Fork 146
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: integrator governance proposal doc (#1027)
- Loading branch information
Showing
3 changed files
with
236 additions
and
150 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
232 changes: 232 additions & 0 deletions
232
src/pages/dev/amplifier/chain-integration/governance-proposals.mdx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,232 @@ | ||
# Chain Integration Governance Proposals | ||
|
||
import { Callout } from "/src/components/callout" | ||
|
||
New chains are onboarded to the Axelar Amplifier through [community governance](/resources/community/community-pool-proposals). In general, you will need to submit five governance proposals to integrate your chain: | ||
|
||
- Proposal to instantiate the verifier contract | ||
- Proposal to instantiate the gateway contract | ||
- Proposal to instantiate the prover contract | ||
- Proposal to register your chain with the router | ||
- Proposal to authorize your prover with the [Amplifier multisig contract](https://github.com/axelarnetwork/axelar-amplifier/blob/main/contracts/multisig/src/msg.rs) | ||
|
||
For example, EVM chain integrators should be using an `instantiate-contract` proposal to use existing `code_id`s, but teams with customized contract needs should use a `store-instantiate` proposal to both store and instantiate their custom code. | ||
|
||
## Prerequisites | ||
|
||
- Access to the [Axelar command-line interface](/learn/cli) | ||
- 2,000 AXL for each proposal, either from your [own wallet](/resources/community/community-pool-proposals#create-a-local-wallet) or through a community member who can fund the proposal within one hour of posting | ||
- A running [RPC endpoint](/resources/rpc/resources) or [Axelar node](/node/config-node) | ||
- Experience with the appropriate Amplifier CosmWasm contracts and interfaces for integrating a chain (i.e. completed the [Integrate a Chain](/dev/amplifier/chain-integration/integrate-a-chain) tutorial) | ||
|
||
## Community Forum introduction | ||
|
||
You will need to introduce your chain to the community in order for Axelar token holders to vote for your proposals. This should be done on the governance section of the [Axelar Community Forum](https://community.axelar.network/c/governance2/33). Make a community introduction post that precedes and can be referenced by any on-chain proposals. It should include the following information: | ||
|
||
- Background | ||
- Governance details | ||
- Pre-deployed source chain gateway address | ||
- Plan for funding rewards pools | ||
|
||
All of your on-chain proposals will refer back to this introduction, so make sure to be thorough. You should stay present and engage with any questions or comments during the seven-day feedback period, which can include public comments as well as a security council review. When the feedback period is over, submit your on-chain governance proposals to finish the integration of your chain. | ||
|
||
<Callout> | ||
Examples were created with contracts on the `ethereum-sepolia` chain. Please refer to [`devnet-amplifier.json`](https://github.com/axelarnetwork/axelar-contract-deployments/blob/main/axelar-chains-config/info/devnet-amplifier.json) for contracts associated with other chains. | ||
</Callout> | ||
|
||
## Proposal to instantiate the verifier contract | ||
|
||
<tabs> | ||
|
||
<tab-item title="EVM integrators"> | ||
|
||
If you are integrating an EVM chain, you can submit a proposal to instantiate the pre-deployed voting verifier contract with the [proper instantiation parameters](https://github.com/axelarnetwork/axelar-amplifier/blob/deab56a75209a158c082cbf9b77caf500eb4ec7c/contracts/voting-verifier/src/msg.rs#L9) using its existing `code_id` (`500`): | ||
|
||
```bash | ||
export CODE_ID=500 | ||
export NETWORK_GOV_ADDRESS="axelar10d07y265gmmuvt4z0w9aw880jnsr700j7v9daj" | ||
export RPC="http://devnet-amplifier.axelar.dev:26657" | ||
``` | ||
|
||
```bash | ||
axelard tx gov submit-proposal instantiate-contract $CODE_ID \ | ||
'{ | ||
"governance_address": "axelar10d07y265gmmuvt4z0w9aw880jnsr700j7v9daj", | ||
"service_registry_address": "axelar1c9fkszt5lq34vvvlat3fxj6yv7ejtqapz04e97vtc9m5z9cwnamq8zjlhz", | ||
"service_name":"validators", | ||
"source_gateway_address":"0xeE9E463Fd8bE9AF266e1B143C27F7D42648f4006", | ||
"voting_threshold":["1","1"], | ||
"block_expiry":10, | ||
"confirmation_height":1, | ||
"source_chain":"ethereum-sepolia", | ||
"rewards_address":"axelar1vaj9sfzc3z0gpel90wu4ljutncutv0wuhvvwfsh30rqxq422z89qnd989l", | ||
"msg_id_format":"hex_tx_hash_and_event_index" | ||
}' \ | ||
--title="Instantiate verifier contract for [chain name]" \ | ||
--description="Instantiate verifier contract for [chain name]" \ | ||
--run-as $NETWORK_GOV_ADDRESS \ | ||
--label "[chain name]" \ | ||
--deposit=2000000000uamplifier \ | ||
--keyring-backend test \ | ||
--from wallet \ | ||
--gas auto --gas-adjustment 1.5 --gas-prices 0.007uamplifier \ | ||
--chain-id=devnet-amplifier \ | ||
--no-admin \ | ||
--node $RPC | ||
``` | ||
|
||
</tab-item> | ||
|
||
</tabs> | ||
|
||
## Proposal to instantiate the gateway contract | ||
|
||
<tabs> | ||
|
||
<tab-item title="EVM integrators"> | ||
If you are integrating an EVM chain, you can submit a proposal to instantiate the pre-deployed gateway contract with the [proper instantiation parameters](https://github.com/axelarnetwork/axelar-amplifier/blob/deab56a75209a158c082cbf9b77caf500eb4ec7c/contracts/gateway/src/msg.rs#L4) using its existing `code_id` (`493`): | ||
|
||
```bash | ||
export CODE_ID=493 | ||
export NETWORK_GOV_ADDRESS="axelar10d07y265gmmuvt4z0w9aw880jnsr700j7v9daj" | ||
export RPC="http://devnet-amplifier.axelar.dev:26657" | ||
``` | ||
|
||
```bash | ||
axelard tx gov submit-proposal instantiate-contract $CODE_ID \ | ||
'{ | ||
"verifier_address": "axelar1e6jnuljng6aljk0tjct6f0hl9tye6l0n9p067pwx2374h82dmr0s9qcqy9", | ||
"router_address": "axelar14jjdxqhuxk803e9pq64w4fgf385y86xxhkpzswe9crmu6vxycezst0zq8y" | ||
}' \ | ||
--title="Instantiate gateway contract for [chain name]" \ | ||
--description="Instantiate gateway contract for [chain name]" \ | ||
--run-as $NETWORK_GOV_ADDRESS \ | ||
--label "[chain name]" \ | ||
--deposit=2000000000uamplifier \ | ||
--keyring-backend test \ | ||
--from wallet \ | ||
--gas auto --gas-adjustment 1.5 --gas-prices 0.007uamplifier \ | ||
--chain-id=devnet-amplifier \ | ||
--no-admin \ | ||
--node $RPC | ||
``` | ||
</tab-item> | ||
|
||
</tabs> | ||
|
||
## Proposal to instantiate the prover contract | ||
|
||
<tabs> | ||
|
||
<tab-item title="EVM integrators"> | ||
If you are integrating an EVM chain, you can submit a proposal to instantiate the pre-deployed prover contract with the [proper instantiation parameters](https://github.com/axelarnetwork/axelar-amplifier/blob/deab56a75209a158c082cbf9b77caf500eb4ec7c/contracts/multisig-prover/src/msg.rs#L12) using its existing `code_id` (`495`): | ||
|
||
```bash | ||
export CODE_ID=495 | ||
export CHAIN_NAME="[chain name]" | ||
export NETWORK_GOV_ADDRESS="axelar10d07y265gmmuvt4z0w9aw880jnsr700j7v9daj" | ||
export RPC="http://devnet-amplifier.axelar.dev:26657" | ||
``` | ||
|
||
```bash | ||
axelard tx gov submit-proposal instantiate-contract $CODE_ID \ | ||
'{ | ||
"admin_address": "axelar1zlr7e5qf3sz7yf890rkh9tcnu87234k6k7ytd9", # Prover admin address | ||
"governance_address": "axelar1zlr7e5qf3sz7yf890rkh9tcnu87234k6k7ytd9", | ||
"gateway_address": "axelar1hdx49xndyxzrs3t5jkzart00taqysu6kmaf77waxv8regwxxpp4qcsea2w" | ||
"multisig_address": "axelar19jxy26z0qnnspa45y5nru0l5rmy9d637z5km2ndjxthfxf5qaswst9290r", | ||
"coordinator_address":"axelar1m2498n4h2tskcsmssjnzswl5e6eflmqnh487ds47yxyu6y5h4zuqr9zk4g", | ||
"service_registry_address":"axelar1c9fkszt5lq34vvvlat3fxj6yv7ejtqapz04e97vtc9m5z9cwnamq8zjlhz", | ||
"voting_verifier_address": "axelar1zlr7e5qf3sz7yf890rkh9tcnu87234k6k7ytd9", # Ethereum Sepolia voting verifier governance address | ||
"signing_threshold": ["1","1"], | ||
"service_name": "validators", | ||
"chain_name": "[chain name]", | ||
"verifier_set_diff_threshold": 1, | ||
"encoder": "abi", | ||
"key_type": "ecdsa", | ||
"domain_separator": "6973c72935604464b28827141b0a463af8e3487616de69c5aa0c785392c9fb9f" # Hash of chain name, admin address, and code ID. Value must be a String in hex format without `0x`. | ||
}' \ | ||
--title="Instantiate prover contract for [chain name]" \ | ||
--description="Instantiate prover contract for [chain name]" \ | ||
--run-as $NETWORK_GOV_ADDRESS \ | ||
--label "[chain name]" \ | ||
--deposit=2000000000uamplifier \ | ||
--keyring-backend test \ | ||
--from wallet \ | ||
--gas auto --gas-adjustment 1.5 --gas-prices 0.007uamplifier \ | ||
--chain-id=devnet-amplifier \ | ||
--admin="axelar1zlr7e5qf3sz7yf890rkh9tcnu87234k6k7ytd9" | ||
--node $RPC | ||
``` | ||
</tab-item> | ||
|
||
</tabs> | ||
|
||
## Register your chain with the router | ||
|
||
```bash | ||
export ROUTER_CONTRACT_ADDRESS="axelar14jjdxqhuxk803e9pq64w4fgf385y86xxhkpzswe9crmu6vxycezst0zq8y" | ||
export ROUTER_GOV_ADDRESS="axelar1zlr7e5qf3sz7yf890rkh9tcnu87234k6k7ytd9" | ||
export RPC="http://devnet-amplifier.axelar.dev:26657" | ||
``` | ||
|
||
```bash | ||
axelard tx gov submit-proposal execute-contract $ROUTER_CONTRACT_ADDRESS \ | ||
'{ | ||
"register_chain": { | ||
"chain":"[Chain name]", | ||
"gateway_address": "[chain gateway address]", | ||
"msg_id_format": "hex_tx_hash_and_event_index" | ||
} | ||
}' \ | ||
--title="Register [chain name] chain with the Amplifier router" \ | ||
--description="Register [chain name] chain with the Amplifier router" \ | ||
--run-as $ROUTER_GOV_ADDRESS \ | ||
--deposit=2000000000uamplifier \ | ||
--keyring-backend test \ | ||
--from wallet \ | ||
--gas auto --gas-adjustment 1.5 --gas-prices 0.007uamplifier \ | ||
--chain-id=devnet-amplifier \ | ||
--node $RPC | ||
``` | ||
|
||
## Authorize your prover with the Amplifier multisig contract | ||
|
||
Once the feedback period has passed, submit the proposal on the command line: | ||
|
||
```bash | ||
export MULTISIG_CONTRACT_ADDRESS="axelar1ufs3tlq4umljk0qfe8k5ya0x6hpavn897u2cnf9k0en9jr7qarqqa9263g" | ||
export MULTISIG_GOV_ADDRESS="axelar1zlr7e5qf3sz7yf890rkh9tcnu87234k6k7ytd9" | ||
export RPC="http://devnet-amplifier.axelar.dev:26657" | ||
``` | ||
|
||
```bash | ||
axelard tx gov submit-proposal execute-contract $MULTISIG_CONTRACT_ADDRESS \ | ||
'{ | ||
"authorize_caller": | ||
{ | ||
"contract_address":"[chain prover address]" | ||
} | ||
}' \ | ||
--title="Authorize [chain name] prover with the Amplifier multisig contract" \ | ||
--description="Authorize [chain name] prover with the Amplifier multisig contract" \ | ||
--run-as $MULTISIG_GOV_ADDRESS \ | ||
--deposit=2000000000uamplifier \ | ||
--keyring-backend test \ | ||
--from wallet \ | ||
--gas auto --gas-adjustment 1.5 --gas-prices 0.007uamplifier \ | ||
--chain-id=devnet-amplifier \ | ||
--node $RPC | ||
``` | ||
|
||
## Track your proposal | ||
|
||
You can track the status of your proposal with the `proposal_id` given in the output after a successful submission. | ||
|
||
## Costs | ||
|
||
Each proposal requires a 2,000 AXL deposit to submit. These funds will be refunded if votes reach quorum. The Axelar Network currently requires a 33.4% quorum of staked tokens. | ||
|
||
## Voting period | ||
|
||
There is a three-day (72-hour) voting period for all mainnet proposals. |
This file was deleted.
Oops, something went wrong.