69da2d5a0c | ||
---|---|---|
.. | ||
contracts | ||
migrations | ||
scripts | ||
test | ||
.dockerignore | ||
.env.template | ||
.env.test | ||
.gitignore | ||
Makefile | ||
README.md | ||
VERIFY.md | ||
conductor_devnet.json | ||
copy-from-container.sh | ||
deploy_contracts.sh | ||
icco_deployment_config.js.sample | ||
package-lock.json | ||
package.json | ||
truffle-config.js | ||
truffle-verify-constants.patch |
README.md
Building
Build the contracts by running make build
.
Testing
Run the tests by running make test
. The tests can be found here.
Deploying ICCO to EVM testnets
To deploy the Conductor and Contributor smart contracts to testnet, follow the procedure below.
Set up the ICCO deployment config. Each network in icco_deployment_config.js
has several parameters:
conductorChainId
- the network that theConductor
contract is (or will be) deployed tocontributorChainId
- the network thatContributor
contract will be deployed toconsistencyLevel
- number of confirmationswormhole
- the wormhole coreBridge addresstokenBridge
-the wormhole tokenBridge addressmnemonic
- private key for deployment walletrpc
- URL for deployment provider
There is a sample config that you can copy to icco_deployment_config.js
to help you get started.
The conductorChainId
and contributorChainId
should be the same only if both contracts are deployed on the same network. ChainIDs for each network can be found here.
Deploy the Conductor
contract with the following command, where your_network
corresponds to a network name from icco_deployment_config.js
.
npm run deploy-conductor your_network
And deploy the Contributor
contract(s) for any network you want to collect contributions from.
npm run deploy-contributor your_network
These commands work for mainnet networks you configure, too. After deploying your contracts, follow the instructions in the README.md in tools/
for Contributor
contract registration.