Skip to content

Commit

Permalink
Testnet redeploy (#79)
Browse files Browse the repository at this point in the history
* fix

* upgrade lib

* testnet redeploy
  • Loading branch information
hujw77 authored Nov 7, 2023
1 parent aff5554 commit 5b5b6a6
Show file tree
Hide file tree
Showing 17 changed files with 36 additions and 36 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ Oracle and Relayer based Message Protocol.
### Canonical Cross-chain Deployment Addresses
| Contract | Canonical Cross-chain Deployment Address |
|------------|--------------------------------------------|
| ORMP | 0x009D223Aad560e72282db9c0438Ef1ef2bf7703D |
| Oracle | 0x00BD655DDfA7aFeF4BB109FE1F938724527B49D8 |
| Relayer | 0x003605167cd4C36063a7B63e604497e623Bb8B10 |
| ORMP | 0x00000000001523057a05d6293C1e5171eE33eE0A |
| Oracle | 0x0000000000ba03146Cc235509E802873D418a6bc |
| Relayer | 0x0000000000808fE9bDCc1d180EfbF5C53552a6b1 |

## Usage
To install with [**Foundry**](https://github.com/gakonst/foundry):
Expand Down
4 changes: 2 additions & 2 deletions bin/deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@

set -eo pipefail

forge script script/deploy/Deploy.s.sol:Deploy --chain-id 44 # --broadcast --verify
forge script script/deploy/Deploy.s.sol:Deploy --chain-id 421614 # --broadcast --verify # --skip-simulation
forge script script/deploy/Deploy.s.sol:Deploy --chain-id 44 --broadcast --verify
forge script script/deploy/Deploy.s.sol:Deploy --chain-id 421614 --broadcast --verify --skip-simulation
2 changes: 1 addition & 1 deletion bin/fee.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ set -eo pipefail

set -x
forge script script/fee/Fee.s.sol:Fee --sig "run(uint256)" 421614 --chain-id 44 --broadcast
forge script script/fee/Fee.s.sol:Fee --sig "run(uint256)" 44 --chain-id 421614 --broadcast # --skip-simulation
forge script script/fee/Fee.s.sol:Fee --sig "run(uint256)" 44 --chain-id 421614 --broadcast --skip-simulation --slow
2 changes: 1 addition & 1 deletion bin/verify.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ set -eo pipefail

c3=$PWD/script/input/c3.json

deployer=$(jq -r ".DEPLOYER" $C3)
deployer=$(jq -r ".DEPLOYER" $c3)
ormp=$(jq -r ".ORMP_ADDR" $c3)
oracle=$(jq -r ".ORACLE_ADDR" $c3)
relayer=$(jq -r ".RELAYER_ADDR" $c3)
Expand Down
2 changes: 1 addition & 1 deletion lib/create3-deploy
26 changes: 13 additions & 13 deletions script/deploy/Deploy.s.sol
Original file line number Diff line number Diff line change
Expand Up @@ -59,12 +59,12 @@ contract Deploy is Common {
config = ScriptTools.readInput(instanceId);
c3 = ScriptTools.readInput("../c3");

ORMP_ADDR = c3.readAddress("ORMP_ADDR");
ORMP_SALT = c3.readBytes32("ORMP_SALT");
ORACLE_ADDR = c3.readAddress("ORACLE_ADDR");
ORACLE_SALT = c3.readBytes32("ORACLE_SALT");
RELAYER_ADDR = c3.readAddress("RELAYER_ADDR");
RELAYER_SALT = c3.readBytes32("RELAYER_SALT");
ORMP_ADDR = c3.readAddress(".ORMP_ADDR");
ORMP_SALT = c3.readBytes32(".ORMP_SALT");
ORACLE_ADDR = c3.readAddress(".ORACLE_ADDR");
ORACLE_SALT = c3.readBytes32(".ORACLE_SALT");
RELAYER_ADDR = c3.readAddress(".RELAYER_ADDR");
RELAYER_SALT = c3.readBytes32(".RELAYER_SALT");

deployer = config.readAddress(".DEPLOYER");
dao = config.readAddress(".DAO");
Expand All @@ -84,7 +84,7 @@ contract Deploy is Common {

ScriptTools.exportContract(outputName, "DAO", dao);
ScriptTools.exportContract(outputName, "ORMP", ORMP_ADDR);
ScriptTools.exportContract(outputName, "ORACLE", ORMP_ADDR);
ScriptTools.exportContract(outputName, "ORACLE", ORACLE_ADDR);
ScriptTools.exportContract(outputName, "RELAYER", RELAYER_ADDR);
}

Expand Down Expand Up @@ -137,13 +137,13 @@ contract Deploy is Common {
III(RELAYER_ADDR).setApproved(relayerOperator, true);
require(III(RELAYER_ADDR).isApproved(relayerOperator), "!r-operator");

III(ORMP_ADDR).changeSetter(dao);
require(III(ORMP_ADDR).setter() == dao, "!dao");
// III(ORMP_ADDR).changeSetter(dao);
// require(III(ORMP_ADDR).setter() == dao, "!dao");

III(ORACLE_ADDR).changeOwner(dao);
require(III(ORACLE_ADDR).owner() == dao, "!dao");
// III(ORACLE_ADDR).changeOwner(dao);
// require(III(ORACLE_ADDR).owner() == dao, "!dao");

III(RELAYER_ADDR).changeOwner(dao);
require(III(RELAYER_ADDR).owner() == dao, "!dao");
// III(RELAYER_ADDR).changeOwner(dao);
// require(III(RELAYER_ADDR).owner() == dao, "!dao");
}
}
2 changes: 1 addition & 1 deletion script/input/421614/oracle.c.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"44": "0x00d917EC19A6b8837ADFcF8adE3D6faF62e0F587"
"44": "0x00000000007317c91F57D86A410934A490E62E1E"
}
2 changes: 1 addition & 1 deletion script/input/44/oracle.c.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"421614": "0x00d917EC19A6b8837ADFcF8adE3D6faF62e0F587"
"421614": "0x00000000007317c91F57D86A410934A490E62E1E"
}
2 changes: 1 addition & 1 deletion script/input/c3.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@
"ORACLE_ADDR": "0x0000000000ba03146Cc235509E802873D418a6bc",
"ORACLE_SALT": "0x7945140b3deab397a3ed2a87a716d03930e85e019b9bd2c21d28713feb5ab1de",
"RELAYER_ADDR": "0x0000000000808fE9bDCc1d180EfbF5C53552a6b1",
"RELATER_SALT": "0x9d38bcb32422a45bc9c08605d4457bcd3dadddfee1573a352ace5f1defa45621"
"RELAYER_SALT": "0x9d38bcb32422a45bc9c08605d4457bcd3dadddfee1573a352ace5f1defa45621"
}
2 changes: 1 addition & 1 deletion script/output/421614/ORMP.v.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion script/output/421614/Oracle.v.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion script/output/421614/Relayer.v.json

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions script/output/421614/deploy.a-latest.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"DAO": "0x0f14341A7f464320319025540E8Fe48Ad0fe5aec",
"ORACLE": "0x00BD655DDfA7aFeF4BB109FE1F938724527B49D8",
"ORMP": "0x009D223Aad560e72282db9c0438Ef1ef2bf7703D",
"RELAYER": "0x003605167cd4C36063a7B63e604497e623Bb8B10"
"ORACLE": "0x0000000000ba03146Cc235509E802873D418a6bc",
"ORMP": "0x00000000001523057a05d6293C1e5171eE33eE0A",
"RELAYER": "0x0000000000808fE9bDCc1d180EfbF5C53552a6b1"
}
2 changes: 1 addition & 1 deletion script/output/44/ORMP.v.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion script/output/44/Oracle.v.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion script/output/44/Relayer.v.json

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions script/output/44/deploy.a-latest.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"DAO": "0x0f14341A7f464320319025540E8Fe48Ad0fe5aec",
"ORACLE": "0x00BD655DDfA7aFeF4BB109FE1F938724527B49D8",
"RELAYER": "0x003605167cd4C36063a7B63e604497e623Bb8B10",
"ORMP": "0x009D223Aad560e72282db9c0438Ef1ef2bf7703D"
"ORACLE": "0x0000000000ba03146Cc235509E802873D418a6bc",
"ORMP": "0x00000000001523057a05d6293C1e5171eE33eE0A",
"RELAYER": "0x0000000000808fE9bDCc1d180EfbF5C53552a6b1"
}

0 comments on commit 5b5b6a6

Please sign in to comment.