Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Managing deployment of complex set of wasm contracts #144

Open
3 tasks
andywer opened this issue Apr 20, 2023 · 1 comment
Open
3 tasks

Managing deployment of complex set of wasm contracts #144

andywer opened this issue Apr 20, 2023 · 1 comment
Labels
enhancement New feature or request

Comments

@andywer
Copy link

andywer commented Apr 20, 2023

Overview (What and Why)

We need to deploy a set of several smart contracts, x-compiled from Solidity to wasm, and maintain that deployment (deploy new contract instances and migrate to them once in a while).

We are building an AMM with an innovative design (0xAmber). In order to deploy it from scratch, you need to deploy

  • Router
  • ERC20-compat contracts (as we need to marry x-compiled solidity contracts with assets being managed by a chain extension)
  • Swap pools
  • Backstop pool (specialty of our design, single-sided liquidity pool)

The pools need to know the router's address, for instance, to authorise calls to permissioned functions. The swap pools also need to be registered with the router, so the router knows where to find them if someone wants to conduct a swap.

So what we ideally would like to use is sort-of a hardhat-deploy, but for Substrate. swanky is a good start, but like one level too low. You still need sort of a runner that checks what contracts have been deployed yet, which ones should be redeployed and then run deployment scripts that invoke swanky.

Find the original question on stack exchange here: https://substrate.stackexchange.com/questions/8157/managing-deployment-of-complex-set-of-wasm-contracts

How

Would require a meta tool on top of swanky, a deployment script runner. Should allow users to easily script procedural deployment scenarios, provide them with the addresses of previously deployed contracts, etc.

Details tbd.

Definition of Done

  • Tool has been built
  • Tool has been documented
  • Tool has been successfully used in a complex real-world use case like ours

Open Issues and Blockers

(Not sure there are any)

@shunsukew shunsukew added the enhancement New feature or request label Apr 28, 2023
@shunsukew
Copy link
Contributor

Thank you for the suggestion.
This is included in our plan #134

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants