Skip to content

Commit

Permalink
feat: introduce ManageDrippie script (#10708)
Browse files Browse the repository at this point in the history
Adds a new script called ManageDrippie that, surprise surprise,
manages Drippie tasks. Replacement for the old stuff that existed
inside of DeployPeriphery because the old stuff was too janky and
relied on making a bunch of smart contract modifications every
time you wanted to add a new drip. Drips can now be added easily
by modifying a JSON configuration file.
  • Loading branch information
smartcontracts authored Jun 4, 2024
1 parent 2919e06 commit 1595335
Show file tree
Hide file tree
Showing 10 changed files with 904 additions and 1,102 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
{
"drippie": "0xd6F935Bd272BEE05bD64096D82970482EF16D64b",
"gelato": "0x859E31b3848Ec384012EECc72C5c49821008296C",

"note": "Object attributes below are prefixed with numbers because of how foundry parses JSON into structs in alphabetical order",
"drips": [
{
"00__name": "FaucetBridgedDrip_opmainnet_V1",
"01__dripcheck": "CheckTrue",
"02__checkparams": {},
"03__recipient": "0xFBb0621E0B23b5478B630BD55a5f21f67730B0F1",
"04__value": 34000000000000000000,
"05__interval": 86400,
"06__data": "0x000000000000000000000000f21d42203af9af1c86e1e8ac501b41f5bc004a0a0000000000000000000000000000000000000000000000000000000000030d4000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000000"
},
{
"00__name": "FaucetBridgedDrip_base_V1",
"01__dripcheck": "CheckTrue",
"02__checkparams": {},
"03__recipient": "0xfd0Bf71F60660E2f608ed56e1659C450eB113120",
"04__value": 34000000000000000000,
"05__interval": 86400,
"06__data": "0x000000000000000000000000f21d42203af9af1c86e1e8ac501b41f5bc004a0a0000000000000000000000000000000000000000000000000000000000030d4000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000000"
},
{
"00__name": "FaucetBridgedDrip_zora_V1",
"01__dripcheck": "CheckTrue",
"02__checkparams": {},
"03__recipient": "0x5376f1D543dcbB5BD416c56C189e4cB7399fCcCB",
"04__value": 34000000000000000000,
"05__interval": 86400,
"06__data": "0x000000000000000000000000f21d42203af9af1c86e1e8ac501b41f5bc004a0a0000000000000000000000000000000000000000000000000000000000030d4000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000000"
},
{
"00__name": "FaucetBridgedDrip_pgn_V1",
"01__dripcheck": "CheckTrue",
"02__checkparams": {},
"03__recipient": "0xFaE6abCAF30D23e233AC7faF747F2fC3a5a6Bfa3",
"04__value": 34000000000000000000,
"05__interval": 86400,
"06__data": "0x000000000000000000000000f21d42203af9af1c86e1e8ac501b41f5bc004a0a0000000000000000000000000000000000000000000000000000000000030d4000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000000"
},
{
"00__name": "FaucetBridgedDrip_orderly_V1",
"01__dripcheck": "CheckTrue",
"02__checkparams": {},
"03__recipient": "0x1Af0494040d6904A9F3EE21921de4b359C736333",
"04__value": 34000000000000000000,
"05__interval": 86400,
"06__data": "0x000000000000000000000000f21d42203af9af1c86e1e8ac501b41f5bc004a0a0000000000000000000000000000000000000000000000000000000000030d4000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000000"
},
{
"00__name": "FaucetBridgedDrip_mode_V1",
"01__dripcheck": "CheckTrue",
"02__checkparams": {},
"03__recipient": "0xbC5C679879B2965296756CD959C3C739769995E2",
"04__value": 34000000000000000000,
"05__interval": 86400,
"06__data": "0x000000000000000000000000f21d42203af9af1c86e1e8ac501b41f5bc004a0a0000000000000000000000000000000000000000000000000000000000030d4000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000000"
},
{
"00__name": "FaucetBridgedDrip_lyra_V1",
"01__dripcheck": "CheckTrue",
"02__checkparams": {},
"03__recipient": "0x915f179A77FB2e1AeA8b56Ebc0D75A7e1A8a7A17",
"04__value": 34000000000000000000,
"05__interval": 86400,
"06__data": "0x000000000000000000000000f21d42203af9af1c86e1e8ac501b41f5bc004a0a0000000000000000000000000000000000000000000000000000000000030d4000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000000"
},
{
"00__name": "FaucetBridgedDrip_lisk_V1",
"01__dripcheck": "CheckTrue",
"02__checkparams": {},
"03__recipient": "0x1Fb30e446eA791cd1f011675E5F3f5311b70faF5",
"04__value": 34000000000000000000,
"05__interval": 86400,
"06__data": "0x000000000000000000000000f21d42203af9af1c86e1e8ac501b41f5bc004a0a0000000000000000000000000000000000000000000000000000000000030d4000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000000"
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
{
"drippie": "0xd6F935Bd272BEE05bD64096D82970482EF16D64b",
"gelato": "0x859E31b3848Ec384012EECc72C5c49821008296C",

"note": "Object attributes below are prefixed with numbers because of how foundry parses JSON into structs in alphabetical order",
"drips": [
{
"00__name": "FaucetDrip_V1",
"01__dripcheck": "CheckBalanceLow",
"02__checkparams": {
"01__target": "0xF21d42203AF9af1C86E1e8ac501B41f5bc004A0a",
"02__threshold": 100000000000000000000
},
"03__recipient": "0xF21d42203AF9af1C86E1e8ac501B41f5bc004A0a",
"04__value": 20000000000000000000,
"05__interval": 3600,
"06__data": ""
},
{
"00__name": "FaucetDrip_V2",
"01__dripcheck": "CheckBalanceLow",
"02__checkparams": {
"01__target": "0xF21d42203AF9af1C86E1e8ac501B41f5bc004A0a",
"02__threshold": 20000000000000000000
},
"03__recipient": "0xF21d42203AF9af1C86E1e8ac501B41f5bc004A0a",
"04__value": 500000000000000000000,
"05__interval": 604800,
"06__data": ""
},
{
"00__name": "FaucetAdminDrip_V1",
"01__dripcheck": "CheckBalanceLow",
"02__checkparams": {
"01__target": "0x212E789D4523D4BAF464f8Fb2A9B9dff2B36e5A6",
"02__threshold": 100000000000000000
},
"03__recipient": "0x212E789D4523D4BAF464f8Fb2A9B9dff2B36e5A6",
"04__value": 1000000000000000000,
"05__interval": 86400,
"06__data": ""
},
{
"00__name": "FaucetGelatoDrip_V1",
"01__dripcheck": "CheckGelatoLow",
"02__checkparams": {
"00__treasury": "0x7506C12a824d73D9b08564d5Afc22c949434755e",
"01__threshold": 100000000000000000,
"02__recipient": "0x0E9b4649eB0760A4F01646636E032D68cFDe58FF"
},
"03__recipient": "0x7506C12a824d73D9b08564d5Afc22c949434755e",
"04__value": 1000000000000000000,
"05__interval": 86400,
"06__data": "0x0000000000000000000000000e9b4649eb0760a4f01646636e032d68cfde58ff"
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
{
"drippie": "0xd6F935Bd272BEE05bD64096D82970482EF16D64b",
"gelato": "0x2A6C106ae13B558BB9E2Ec64Bd2f1f7BEFF3A5E0",

"note": "Object attributes below are prefixed with numbers because of how foundry parses JSON into structs in alphabetical order",
"drips": [
{
"00__name": "OperationsSequencerDrip_V1",
"01__dripcheck": "CheckBalanceLow",
"02__checkparams": {
"01__target": "0x8F23BB38F531600e5d8FDDaAEC41F13FaB46E98c",
"02__threshold": 100000000000000000000
},
"03__recipient": "0x8F23BB38F531600e5d8FDDaAEC41F13FaB46E98c",
"04__value": 20000000000000000000,
"05__interval": 86400,
"06__data": ""
},
{
"00__name": "OperationsProposerDrip_V1",
"01__dripcheck": "CheckBalanceLow",
"02__checkparams": {
"01__target": "0x49277EE36A024120Ee218127354c4a3591dc90A9",
"02__threshold": 100000000000000000000
},
"03__recipient": "0x49277EE36A024120Ee218127354c4a3591dc90A9",
"04__value": 20000000000000000000,
"05__interval": 86400,
"06__data": ""
},
{
"00__name": "OperationsGelatoDrip_V1",
"01__dripcheck": "CheckGelatoLow",
"02__checkparams": {
"00__treasury": "0x7506C12a824d73D9b08564d5Afc22c949434755e",
"01__threshold": 1000000000000000000,
"02__recipient": "0x03C256F7Ae7518D0fe489F257ab4b928D37CBE16"
},
"03__recipient": "0x7506C12a824d73D9b08564d5Afc22c949434755e",
"04__value": 1000000000000000000,
"05__interval": 86400,
"06__data": "0x00000000000000000000000003c256f7ae7518d0fe489f257ab4b928d37cbe16"
},
{
"00__name": "OperationsSecretsDrip_V1",
"01__dripcheck": "CheckSecrets",
"02__checkparams": {
"00__delay": 43200,
"01__secretHashMustExist": "0x565fa8c7daa859353b5b328b97b12c7d66c5832b2a24d4e0f739a65ad266a46f",
"02__secretHashMustNotExist": "0xbc362b01d69a85dff1793803dde67df1f338f37a36fdc73dddf27283d215e614"
},
"03__recipient": "0x03C256F7Ae7518D0fe489F257ab4b928D37CBE16",
"04__value": 1000000000000000000,
"05__interval": 3600,
"06__data": ""
}
]
}
52 changes: 3 additions & 49 deletions packages/contracts-bedrock/periphery-deploy-config/sepolia.json
Original file line number Diff line number Diff line change
@@ -1,43 +1,11 @@
{
"create2DeploymentSalt": "0.0.2",
"create2DeploymentSalt": "0.0.3",

"gelatoAutomateContract": "0x2A6C106ae13B558BB9E2Ec64Bd2f1f7BEFF3A5E0",
"gelatoTreasuryContract": "0x7506C12a824d73D9b08564d5Afc22c949434755e",

"operationsDrippieOwner": "0x03C256F7Ae7518D0fe489F257ab4b928D37CBE16",
"operationsSequencerDripV1Target": "0x8F23BB38F531600e5d8FDDaAEC41F13FaB46E98c",
"operationsSequencerDripV1Value": 20000000000000000000,
"operationsSequencerDripV1Interval": 86400,
"operationsSequencerDripV1Threshold": 100000000000000000000,
"operationsGelatoDripV1Recipient": "0x03C256F7Ae7518D0fe489F257ab4b928D37CBE16",
"operationsGelatoDripV1Value": 1000000000000000000,
"operationsGelatoDripV1Interval": 86400,
"operationsGelatoDripV1Threshold": 500000000000000000,
"operationsSecretsDripV1Delay": 43200,
"operationsSecretsDripV1MustExist": "0x565fa8c7daa859353b5b328b97b12c7d66c5832b2a24d4e0f739a65ad266a46f",
"operationsSecretsDripV1MustNotExist": "0xbc362b01d69a85dff1793803dde67df1f338f37a36fdc73dddf27283d215e614",
"operationsSecretsDripV1Target": "0x03C256F7Ae7518D0fe489F257ab4b928D37CBE16",
"operationsSecretsDripV1Value": 1000000000000000000,
"operationsSecretsDripV1Interval": 3600,

"faucetDrippieOwner": "0x10ab157483dd308f8B38aCF2ad823dfD255F56b5",
"faucetDripV1Value": 20000000000000000000,
"faucetDripV1Interval": 3600,
"faucetDripV1Threshold": 100000000000000000000,
"faucetDripV2Value": 500000000000000000000,
"faucetDripV2Interval": 604800,
"faucetDripV2Threshold": 20000000000000000000,
"faucetAdminDripV1Value": 1000000000000000000,
"faucetAdminDripV1Interval": 86400,
"faucetAdminDripV1Threshold": 100000000000000000,
"faucetGelatoRecipient": "0x0E9b4649eB0760A4F01646636E032D68cFDe58FF",
"faucetGelatoBalanceV1DripInterval": 86400,
"faucetGelatoBalanceV1Value": 1000000000000000000,
"faucetGelatoThreshold": 100000000000000000,
"smallOpChainFaucetDripValue": 34000000000000000000,
"smallOpChainFaucetDripInterval": 86400,
"largeOpChainFaucetDripValue": 34000000000000000000,
"largeOpChainFaucetDripInterval": 86400,

"opChainAdminWalletDripValue": 1000000000000000000,
"opChainAdminWalletDripInterval": 2592000,

Expand All @@ -49,21 +17,7 @@
"faucetOffchainAuthModuleTtl": 86400,
"faucetOffchainAuthModuleAmount": 50000000000000000,

"opL1BridgeAddress": "0xFBb0621E0B23b5478B630BD55a5f21f67730B0F1",
"baseL1BridgeAddress": "0xfd0Bf71F60660E2f608ed56e1659C450eB113120",
"zoraL1BridgeAddress": "0x5376f1D543dcbB5BD416c56C189e4cB7399fCcCB",
"pgnL1BridgeAddress": "0xFaE6abCAF30D23e233AC7faF747F2fC3a5a6Bfa3",
"orderlyL1BridgeAddress": "0x1Af0494040d6904A9F3EE21921de4b359C736333",
"modeL1BridgeAddress": "0xbC5C679879B2965296756CD959C3C739769995E2",
"lyraL1BridgeAddress": "0x915f179A77FB2e1AeA8b56Ebc0D75A7e1A8a7A17",
"liskL1BridgeAddress": "0x1Fb30e446eA791cd1f011675E5F3f5311b70faF5",

"deployDripchecks": true,
"deployFaucetContracts": false,
"deployOperationsContracts": true,
"installOpChainFaucetsDrips": false,
"archivePreviousOpChainFaucetsDrips": false,

"dripVersion": 3,
"previousDripVersion": 2
"deployOperationsContracts": true
}
Loading

0 comments on commit 1595335

Please sign in to comment.