Skip to content

Commit

Permalink
added metis rebase controller deployment scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
BkChoy committed Dec 13, 2024
1 parent 67d8ac5 commit 15e2a93
Show file tree
Hide file tree
Showing 4 changed files with 33 additions and 3 deletions.
3 changes: 0 additions & 3 deletions scripts/prod/1.0.0-metis-staking/3-setup-metis-staking-l2.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
import { L2Transmitter } from '../../../typechain-types/contracts/metisStaking/L2Transmitter'
import { getContract } from '../../utils/deployment'
import { switchNetwork } from '../../utils/helpers'

const l1Transmitter = ''

async function main() {
await switchNetwork(1088, '')

const l2Transmitter = (await getContract('METIS_L2Transmitter', true)) as L2Transmitter

await (await l2Transmitter.setL1Transmitter(l1Transmitter)).wait()
Expand Down
33 changes: 33 additions & 0 deletions scripts/prod/1.0.0-metis-staking/4-deploy-rebase-controller.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
import { ethers } from 'hardhat'
import { deploy, getContract, updateDeployments } from '../../utils/deployment'

const emergencyPauser = '' // address authorized to pause pool in case of emergency

async function main() {
const priorityPool = await getContract('METIS_PriorityPool')
const stakingPool = await getContract('METIS_StakingPool')

const rebaseController = await deploy('RebaseController', [
stakingPool.target,
priorityPool.target,
ethers.ZeroAddress,
emergencyPauser,
])
console.log('METIS_RebaseController deployed: ', rebaseController.target)

updateDeployments(
{
METIS_RebaseController: rebaseController.target,
},
{
METIS_RebaseController: 'RebaseController',
}
)
}

main()
.then(() => process.exit(0))
.catch((error) => {
console.error(error)
process.exit(1)
})

0 comments on commit 15e2a93

Please sign in to comment.