Skip to content

Commit b174f75

Browse files
authored
Merge pull request #19 from HerodotusDev/development
Upgrade scripts + legacy aggregators + Arbitrum parent hash fetcher
2 parents 24828de + 3980e4b commit b174f75

34 files changed

+840
-76
lines changed

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@ docs/
1010

1111
# Dotenv file
1212
.env
13-
.env.cicd
13+
.env.*
14+
!.env.example
1415

1516
# Node modules
1617
node_modules/

README.md

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ Because of great complexity of the contract and need for fine-tuned upgradabilit
8888

8989
## Deployment
9090

91-
1. Create `.env` file using `.env.example` template. You will need `PRIVATE_KEY` of EVM deployment account and `ALCHEMY_API_KEY` which you can get from [TODO link](). Make sure that you enabled chains you need. Additionally, you will need API key for block explorers of chains you want to deploy to (`*CHAIN_NAME*_ETHERSCAN_API_KEY`).
91+
1. Create `.env` file using `.env.example` template. You will need `PRIVATE_KEY` of EVM deployment account and `ALCHEMY_API_KEY` which you can get from [Alchemy dashboard](https://dashboard.alchemy.com). Make sure that you enabled chains you need. Additionally, you will need API key for block explorers of chains you want to deploy to (`*CHAIN_NAME*_ETHERSCAN_API_KEY`).
9292

9393
2. Compile your contract with
9494

@@ -105,9 +105,15 @@ bun satellite:deploy CHAIN_ID
105105
> Note: Addresses of deployed contracts are saved to `deployed_satellites.json`. If contract for chain id, which you want to deploy, already exists in the config, it will fail. If you want to erase data about deployed contracts run
106106
>
107107
> ```
108-
> bun erase_deployed_satellites
108+
> bun detach_satellites
109109
> ```
110110
111+
To connect two satellites that support messaging, run
112+
113+
```
114+
bun connection:register SENDER_CHAIN_ID RECEIVER_CHAIN_ID
115+
```
116+
111117
### Upgrades
112118
113119
To upgrade existing satellite, run steps 1 and 2 from section above and then run
@@ -116,6 +122,20 @@ To upgrade existing satellite, run steps 1 and 2 from section above and then run
116122
bun satellite:upgrade CHAIN_ID
117123
```
118124
125+
### Removing satellites and connections
126+
127+
To remove connection between two satellites, run
128+
129+
```
130+
bun connection:remove SENDER_CHAIN_ID RECEIVER_CHAIN_ID
131+
```
132+
133+
When all connections to/from satellite are removed, you can remove satellite with
134+
135+
```
136+
bun satellite:remove CHAIN_ID
137+
```
138+
119139
## Documentation
120140
121141
Here are some useful links for further reading:

abi/11155111.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2438,4 +2438,4 @@
24382438
"stateMutability": "nonpayable",
24392439
"type": "function"
24402440
}
2441-
]
2441+
]

abi/11155420.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1727,4 +1727,4 @@
17271727
"stateMutability": "nonpayable",
17281728
"type": "function"
17291729
}
1730-
]
1730+
]

abi/300.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1727,4 +1727,4 @@
17271727
"stateMutability": "nonpayable",
17281728
"type": "function"
17291729
}
1730-
]
1730+
]

abi/33111.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1727,4 +1727,4 @@
17271727
"stateMutability": "nonpayable",
17281728
"type": "function"
17291729
}
1730-
]
1730+
]

abi/421614.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1844,4 +1844,4 @@
18441844
"stateMutability": "nonpayable",
18451845
"type": "function"
18461846
}
1847-
]
1847+
]

abi/4801.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1727,4 +1727,4 @@
17271727
"stateMutability": "nonpayable",
17281728
"type": "function"
17291729
}
1730-
]
1730+
]

deployed_satellites.json

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,14 @@
2727
{
2828
"chainId": "393402133025997798000961",
2929
"contractAddress": "0x06d523b16d7f6f71e250fc7f8d95df3e9e987a120878ea1a25ff312d92f42c8e"
30+
},
31+
{
32+
"chainId": "1",
33+
"contractAddress": "0x8c26F9caD52c1F6b6fFaA5991bC71e3F6F2cd693"
34+
},
35+
{
36+
"chainId": "393402131332719809807700",
37+
"contractAddress": "0x0373d8a2c0f57f178b218fffff787015dc84a68de8ede2a1ba42fb273b3e0b62"
3038
}
3139
],
3240
"connections": [
@@ -55,4 +63,4 @@
5563
"to": "393402133025997798000961"
5664
}
5765
]
58-
}
66+
}

deployed_satellites_prod.json

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
{
2+
"satellites": [
3+
{
4+
"chainId": "1",
5+
"contractAddress": "0x2E6F182B06F37CbDC966Ff5471c7D98cec2bfe70"
6+
},
7+
{
8+
"chainId": "11155111",
9+
"contractAddress": "0x396bF739f7b37D81f6CdD4571fDEF298150db88f"
10+
},
11+
{
12+
"chainId": "300",
13+
"contractAddress": "0xcFe10E57380D22892DC59cC181e66A19C567CAEB"
14+
},
15+
{
16+
"chainId": "11155420",
17+
"contractAddress": "0x495F332aDb2b5134f4633F5AeDF981bd1A6be3A0"
18+
},
19+
{
20+
"chainId": "421614",
21+
"contractAddress": "0x160416c6721db82A312A09D78dfBeC446F7a3a9d"
22+
},
23+
{
24+
"chainId": "33111",
25+
"contractAddress": "0x33f4d13f2D491b0bdc3451046708De0DeD794207"
26+
},
27+
{
28+
"chainId": "4801",
29+
"contractAddress": "0xd198Fa56B4b457223C67D075374b9Efc84DBAe0d"
30+
},
31+
{
32+
"chainId": "393402133025997798000961",
33+
"contractAddress": "0x00421cd95f9ddabdd090db74c9429f257cb6bc1ccc339278d1db1de39156676e"
34+
},
35+
{
36+
"chainId": "393402131332719809807700",
37+
"contractAddress": "0x01ba7d4b5707f8878c22fb335763abfc26c2ae157c434d597f6416fe6a79bf2e"
38+
}
39+
],
40+
"connections": [
41+
{
42+
"from": "11155111",
43+
"to": "300"
44+
},
45+
{
46+
"from": "11155111",
47+
"to": "11155420"
48+
},
49+
{
50+
"from": "11155111",
51+
"to": "421614"
52+
},
53+
{
54+
"from": "421614",
55+
"to": "33111"
56+
},
57+
{
58+
"from": "11155111",
59+
"to": "4801"
60+
},
61+
{
62+
"from": "11155111",
63+
"to": "393402133025997798000961"
64+
},
65+
{
66+
"from": "1",
67+
"to": "393402131332719809807700"
68+
}
69+
]
70+
}

0 commit comments

Comments
 (0)