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

[sepolia] deploy revshare contracts to sepolia #119

Merged
merged 10 commits into from
Jan 29, 2024

Conversation

cody-wang-cb
Copy link
Contributor

@cody-wang-cb cody-wang-cb commented Jan 24, 2024

Similar to this task https://github.com/base-org/contract-deployments/tree/main/goerli/2023-08-23-deploy-revshare, to deploy revenue share contracts to sepolia.

The contracts are identical to the goerli contracts.

Deployed contracts:

In addition, added another script UpdateFeeVaultRecipient.s.sol to deploy new L2 fee vaults contract in order to point the recipients to the FeeDisburser. This is needed since recipient is immutable.
This script needs to be ran by the ProxyAdmin.

sepolia/2024-01-22-deploy-revshare/.env Show resolved Hide resolved
BATCH_SENDER=0x6CDEbe940BC0F26850285cacA097C11c33103E47
OUTPUT_PROPOSER_TARGET_BALANCE=200000000000000000000
BATCH_SENDER_TARGET_BALANCE=1000000000000000000000
BALANCE_TRACKER_ADMIN=0x608081689Fe46936fB2fBDF7552CbB1D80ad4822
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is correct! but we do want to eventually change these admins to being the Gnosis safes we setup so would be ideal if we just set that to be the admin to avoid another owernship transfer later

FEE_DISBURSER_DEPLOYER=<>
OPTIMISM_WALLET=<>
FEE_DISBURSEMENT_INTERVAL=604800 # 60 seconds * 60 minutes * 24 hours * 7 days
FEE_DISBURSER_ADMIN=0x8937037a0bb08658e5a178c182e60b12f14720ce
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cast call --rpc-url https://base-sepolia.cbhq.net 0x4200000000000000000000000000000000000018 "owner()"

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same comment as above

BASE_CONTRACTS_COMMIT=8e56038610812dc8411f9fc6ecbef2cba613b913

# BalanceTracker configuration
BALANCE_TRACKER_DEPLOYER=<>
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think BALANCE_TRACKER_DEPLOYER and FEE_DISBURSER_DEPLOYER are filled in when the deploy happens?
(the address of the EOA wallet deployer)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We'd want to allocate a new key for this - let's sync offline!


# BalanceTracker configuration
BALANCE_TRACKER_DEPLOYER=<>
PROFIT_WALLET=<>
Copy link
Contributor Author

@cody-wang-cb cody-wang-cb Jan 24, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not very sure where to find PROFIT_WALLET and OPTIMISM_WALLET for sepolia, would love some hints on this one

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you can use what we used for Goerli (0x5a822ea15764a6090b86b1eabffc051cec99afe9) for both values. This is a coinbase managed key

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Although if we're anyways allocating an address for deploying, might be a good idea to allocate a new one here as well

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated it to 0x5a822ea15764a6090b86b1eabffc051cec99afe9 for now!

sepolia/2024-01-22-deploy-revshare/.env Outdated Show resolved Hide resolved
Comment on lines 36 to 44
.PHONY: sign-cb
sign-cb:
$(GOPATH)/bin/eip712sign --ledger --hd-paths "m/44'/60'/$(LEDGER_ACCOUNT)'/0/0" -- \
forge script UpgradeToFeeDisburser --via-ir --rpc-url $(L2_RPC_URL) UpgradeToFeeDisburser --sig "sign()"

.PHONY: execute
execute:
@forge script UpgradeToFeeDisburser --rpc-url $(L2_RPC_URL) UpgradeToFeeDisburser \
--sig "run(bytes)" $(SIGNATURES) --private-key ${PRIVATE_KEY} --sender $(SENDER)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it possible to run local test for this multisig script? I tried to pass in --private-key $(PRIVATE_KEY) with my own private key and using my wallet address for CB_SAFE_ADDRESS to run sign-cb but it throws Revert error.
Not sure if that's the proper way to do it though

@cody-wang-cb cody-wang-cb changed the title [sepolia] deploy revshare contracts to sepolia [sepolia] deploy revshare contracts to sepolia (WIP) Jan 24, 2024
@cody-wang-cb cody-wang-cb changed the title [sepolia] deploy revshare contracts to sepolia (WIP) [sepolia] deploy revshare contracts to sepolia Jan 25, 2024
@cb-heimdall
Copy link
Collaborator

Review Error for mdehoog @ 2024-01-29 19:00:51 UTC
User failed mfa authentication, public email is not set on your github profile. see go/mfa-help

@cody-wang-cb cody-wang-cb merged commit ec542ba into main Jan 29, 2024
4 checks passed
@cody-wang-cb cody-wang-cb deleted the cody/deploy_revshare_sepolia branch January 29, 2024 19:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants