mirror of
https://github.com/tornadocash/tornado-nova
synced 2024-02-02 14:53:56 +01:00
update deploy scripts
This commit is contained in:
parent
f78bb5d597
commit
a9a0a7f8c2
@ -1,16 +1,16 @@
|
|||||||
const { ethers } = require('hardhat')
|
const { ethers } = require('hardhat')
|
||||||
|
|
||||||
// This script deploys WETHOmnibridgeRouter to FOREIGN chain (mainnet)
|
// This script deploys L1Helper to FOREIGN chain (mainnet)
|
||||||
|
|
||||||
async function main() {
|
async function main() {
|
||||||
const owner = '0x03Ebd0748Aa4D1457cF479cce56309641e0a98F5'
|
const owner = '0x03Ebd0748Aa4D1457cF479cce56309641e0a98F5'
|
||||||
const omniBridge = '0xf0b456250dc9990662a6f25808cc74a6d1131ea9'
|
const omniBridge = '0xf0b456250dc9990662a6f25808cc74a6d1131ea9'
|
||||||
const token = '0xbb4CdB9CBd36B01bD1cBaEBF2De08d9173bc095c' // WBNB
|
const token = '0xbb4CdB9CBd36B01bD1cBaEBF2De08d9173bc095c' // WBNB
|
||||||
|
|
||||||
const Helper = await ethers.getContractFactory('WETHOmnibridgeRouter')
|
const Helper = await ethers.getContractFactory('L1Helper')
|
||||||
const helper = await Helper.deploy(omniBridge, token, owner)
|
const helper = await Helper.deploy(omniBridge, token, owner)
|
||||||
await helper.deployed()
|
await helper.deployed()
|
||||||
console.log(`WETHOmnibridgeRouter address: ${helper.address}`)
|
console.log(`L1Helper address: ${helper.address}`)
|
||||||
}
|
}
|
||||||
|
|
||||||
main()
|
main()
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
const { ethers } = require('hardhat')
|
const { ethers } = require('hardhat')
|
||||||
|
const { utils } = ethers
|
||||||
|
|
||||||
const MERKLE_TREE_HEIGHT = 23
|
const MERKLE_TREE_HEIGHT = 23
|
||||||
const { MINIMUM_WITHDRAWAL_AMOUNT, MAXIMUM_DEPOSIT_AMOUNT } = process.env
|
const { MINIMUM_WITHDRAWAL_AMOUNT, MAXIMUM_DEPOSIT_AMOUNT } = process.env
|
||||||
@ -36,7 +37,7 @@ async function main() {
|
|||||||
token,
|
token,
|
||||||
omniBridge,
|
omniBridge,
|
||||||
l1Unwrapper,
|
l1Unwrapper,
|
||||||
l1ChainId,
|
govAddress,
|
||||||
)
|
)
|
||||||
await tornadoImpl.deployed()
|
await tornadoImpl.deployed()
|
||||||
console.log(`TornadoPool implementation address: ${tornadoImpl.address}`)
|
console.log(`TornadoPool implementation address: ${tornadoImpl.address}`)
|
||||||
@ -47,7 +48,14 @@ async function main() {
|
|||||||
console.log(`proxy address: ${proxy.address}`)
|
console.log(`proxy address: ${proxy.address}`)
|
||||||
|
|
||||||
const tornadoPool = await Pool.attach(proxy.address)
|
const tornadoPool = await Pool.attach(proxy.address)
|
||||||
await tornadoPool.initialize(MINIMUM_WITHDRAWAL_AMOUNT, MAXIMUM_DEPOSIT_AMOUNT)
|
|
||||||
|
await tornadoPool.initialize(
|
||||||
|
utils.parseEther(MINIMUM_WITHDRAWAL_AMOUNT),
|
||||||
|
utils.parseEther(MAXIMUM_DEPOSIT_AMOUNT),
|
||||||
|
)
|
||||||
|
console.log(
|
||||||
|
`Proxy initialized with MINIMUM_WITHDRAWAL_AMOUNT=${MINIMUM_WITHDRAWAL_AMOUNT} ETH and MAXIMUM_DEPOSIT_AMOUNT=${MAXIMUM_DEPOSIT_AMOUNT} ETH`,
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
main()
|
main()
|
||||||
|
Loading…
Reference in New Issue
Block a user