Skip to content

How is the vault deployed?

Nothing is deployed yet. These are the steps.

  1. Build: pnpm vault:build.
  2. Test: pnpm vault:test.
  3. Compute the address: pnpm vault:address.
  4. Fund the deployer with a little ETH. Check the current gas price first.
  5. Dry run: pnpm vault:deploy. Use the runbook to send it on chain.
  6. Verify the code on Blockscout.

The deploy uses the CREATE2 factory. The args come from VAULT_OWNER and VAULT_OPERATOR. When the deployer is the owner, the script allows the Universal Router.

Terminal window
pnpm vault:build && pnpm vault:test && pnpm vault:address

Full commands are in deployment/vault/README.md. The vault code is in packages/vault.

pnpm vault:address writes deployment/vault/address.json. You can deploy later. Keep the code, salt, and args fixed to keep this address.

Read how to fund it.