Skip to content

Commit 4d81960

Browse files
Merge pull request Synthetixio#738 from Synthetixio/providers-other-than-infura
Prepares scripts for deploying in Goerli OVM
2 parents 3281166 + 340d757 commit 4d81960

24 files changed

+381
-27
lines changed

.env.example

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
ETHERSCAN_KEY=SomeEtherscanKey
2-
INFURA_PROJECT_ID=SomeInfuraKey
2+
PROVIDER_URL=https://network.infura.io/v3/SomeInfuraKey
33
DEPLOY_PRIVATE_KEY= new one SomeEthereumPrivateKey (including 0x prefix)
44
TESTNET_DEPLOY_PRIVATE_KEY=new one SomeEthereumPrivateKey (including 0x prefix)
55
CIRCLECI_TOKEN=Create one via https://app.circleci.com/settings/user/tokens

index.js

+10-1
Original file line numberDiff line numberDiff line change
@@ -33,16 +33,24 @@ const data = {
3333
rewards: require('./publish/deployed/mainnet/rewards.json'),
3434
feeds: require('./publish/deployed/mainnet/feeds.json'),
3535
},
36+
goerli: {
37+
deployment: require('./publish/deployed/goerli/deployment.json'),
38+
versions: require('./publish/deployed/goerli/versions.json'),
39+
synths: require('./publish/deployed/goerli/synths.json'),
40+
rewards: require('./publish/deployed/goerli/rewards.json'),
41+
feeds: require('./publish/deployed/goerli/feeds.json'),
42+
},
3643
};
3744

3845
const assets = require('./publish/assets.json');
3946

40-
const networks = ['local', 'kovan', 'rinkeby', 'ropsten', 'mainnet'];
47+
const networks = ['local', 'kovan', 'rinkeby', 'ropsten', 'mainnet', 'goerli'];
4148

4249
const networkToChainId = {
4350
mainnet: 1,
4451
ropsten: 3,
4552
rinkeby: 4,
53+
goerli: 5,
4654
kovan: 42,
4755
};
4856

@@ -338,6 +346,7 @@ const getUsers = ({ network = 'mainnet', user } = {}) => {
338346
kovan: Object.assign({}, base),
339347
rinkeby: Object.assign({}, base),
340348
ropsten: Object.assign({}, base),
349+
goerli: Object.assign({}, base),
341350
};
342351

343352
const users = Object.entries(map[network]).map(([key, value]) => ({ name: key, address: value }));

package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,8 @@
5252
"publish/deployed/kovan/*.json",
5353
"publish/deployed/rinkeby/*.json",
5454
"publish/deployed/ropsten/*.json",
55-
"publish/deployed/mainnet/*.json"
55+
"publish/deployed/mainnet/*.json",
56+
"publish/deployed/goerli/*.json"
5657
],
5758
"bin": {
5859
"snx": "bin.js"
+125
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,125 @@
1+
{
2+
"SystemSettings": {
3+
"deploy": true
4+
},
5+
"AddressResolver": {
6+
"deploy": true
7+
},
8+
"ReadProxyAddressResolver": {
9+
"deploy": true
10+
},
11+
"Depot": {
12+
"deploy": true
13+
},
14+
"TradingRewards": {
15+
"deploy": true
16+
},
17+
"EscrowChecker": {
18+
"deploy": true
19+
},
20+
"ExchangeRates": {
21+
"deploy": true
22+
},
23+
"Exchanger": {
24+
"deploy": true
25+
},
26+
"ExchangeState": {
27+
"deploy": true
28+
},
29+
"EtherCollateral": {
30+
"deploy": true
31+
},
32+
"FeePool": {
33+
"deploy": true
34+
},
35+
"FeePoolState": {
36+
"deploy": true
37+
},
38+
"FeePoolEternalStorage": {
39+
"deploy": true
40+
},
41+
"FlexibleStorage": {
42+
"deploy": true
43+
},
44+
"DelegateApprovals": {
45+
"deploy": true
46+
},
47+
"DelegateApprovalsEternalStorage": {
48+
"deploy": true
49+
},
50+
"Issuer": {
51+
"deploy": true
52+
},
53+
"EternalStorageLiquidations": {
54+
"deploy": true
55+
},
56+
"Liquidations": {
57+
"deploy": true
58+
},
59+
"SupplySchedule": {
60+
"deploy": true
61+
},
62+
"Synthetix": {
63+
"deploy": true
64+
},
65+
"SynthetixEscrow": {
66+
"deploy": true
67+
},
68+
"RewardEscrow": {
69+
"deploy": true
70+
},
71+
"RewardsDistribution": {
72+
"deploy": true
73+
},
74+
"SynthetixState": {
75+
"deploy": true
76+
},
77+
"SystemStatus": {
78+
"deploy": true
79+
},
80+
"SynthUtil": {
81+
"deploy": true
82+
},
83+
"DappMaintenance": {
84+
"deploy": true
85+
},
86+
"SynthsUSD": {
87+
"deploy": true
88+
},
89+
"ProxyERC20": {
90+
"deploy": true
91+
},
92+
"ProxyERC20sUSD": {
93+
"deploy": true
94+
},
95+
"ProxyFeePool": {
96+
"deploy": true
97+
},
98+
"ProxySynthetix": {
99+
"deploy": true
100+
},
101+
"ProxysUSD": {
102+
"deploy": true
103+
},
104+
"SafeDecimalMath": {
105+
"deploy": true
106+
},
107+
"Math": {
108+
"deploy": true
109+
},
110+
"TokenStateSynthetix": {
111+
"deploy": true
112+
},
113+
"TokenStatesUSD": {
114+
"deploy": true
115+
},
116+
"TokenStatesETH": {
117+
"deploy": true
118+
},
119+
"ProxysETH": {
120+
"deploy": true
121+
},
122+
"SynthsETH": {
123+
"deploy": true
124+
}
125+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"targets": {},
3+
"sources": {}
4+
}
+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"SNX": {"asset": "SNX", "feed": "0x0"}
3+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{}
+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
[]
+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
[]
+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
[
2+
{
3+
"name": "sUSD",
4+
"asset": "USD"
5+
},
6+
{
7+
"name": "sETH",
8+
"asset": "ETH",
9+
"subclass": "MultiCollateralSynth"
10+
}
11+
]
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{}

publish/deployed/goerli/config.json

+125
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,125 @@
1+
{
2+
"SystemSettings": {
3+
"deploy": true
4+
},
5+
"AddressResolver": {
6+
"deploy": true
7+
},
8+
"ReadProxyAddressResolver": {
9+
"deploy": true
10+
},
11+
"Depot": {
12+
"deploy": true
13+
},
14+
"TradingRewards": {
15+
"deploy": true
16+
},
17+
"EscrowChecker": {
18+
"deploy": true
19+
},
20+
"ExchangeRates": {
21+
"deploy": true
22+
},
23+
"Exchanger": {
24+
"deploy": true
25+
},
26+
"ExchangeState": {
27+
"deploy": true
28+
},
29+
"EtherCollateral": {
30+
"deploy": true
31+
},
32+
"FeePool": {
33+
"deploy": true
34+
},
35+
"FeePoolState": {
36+
"deploy": true
37+
},
38+
"FeePoolEternalStorage": {
39+
"deploy": true
40+
},
41+
"FlexibleStorage": {
42+
"deploy": true
43+
},
44+
"DelegateApprovals": {
45+
"deploy": true
46+
},
47+
"DelegateApprovalsEternalStorage": {
48+
"deploy": true
49+
},
50+
"Issuer": {
51+
"deploy": true
52+
},
53+
"EternalStorageLiquidations": {
54+
"deploy": true
55+
},
56+
"Liquidations": {
57+
"deploy": true
58+
},
59+
"SupplySchedule": {
60+
"deploy": true
61+
},
62+
"Synthetix": {
63+
"deploy": true
64+
},
65+
"SynthetixEscrow": {
66+
"deploy": true
67+
},
68+
"RewardEscrow": {
69+
"deploy": true
70+
},
71+
"RewardsDistribution": {
72+
"deploy": true
73+
},
74+
"SynthetixState": {
75+
"deploy": true
76+
},
77+
"SystemStatus": {
78+
"deploy": true
79+
},
80+
"SynthUtil": {
81+
"deploy": true
82+
},
83+
"DappMaintenance": {
84+
"deploy": true
85+
},
86+
"SynthsUSD": {
87+
"deploy": true
88+
},
89+
"ProxyERC20": {
90+
"deploy": true
91+
},
92+
"ProxyERC20sUSD": {
93+
"deploy": true
94+
},
95+
"ProxyFeePool": {
96+
"deploy": true
97+
},
98+
"ProxySynthetix": {
99+
"deploy": true
100+
},
101+
"ProxysUSD": {
102+
"deploy": true
103+
},
104+
"SafeDecimalMath": {
105+
"deploy": true
106+
},
107+
"Math": {
108+
"deploy": true
109+
},
110+
"TokenStateSynthetix": {
111+
"deploy": true
112+
},
113+
"TokenStatesUSD": {
114+
"deploy": true
115+
},
116+
"TokenStatesETH": {
117+
"deploy": true
118+
},
119+
"ProxysETH": {
120+
"deploy": true
121+
},
122+
"SynthsETH": {
123+
"deploy": true
124+
}
125+
}
+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"targets": {},
3+
"sources": {}
4+
}

publish/deployed/goerli/feeds.json

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"SNX": {"asset": "SNX", "feed": "0x0"}
3+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{}

publish/deployed/goerli/params.json

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
[]

publish/deployed/goerli/rewards.json

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
[]

publish/deployed/goerli/synths.json

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
[
2+
{
3+
"name": "sUSD",
4+
"asset": "USD"
5+
},
6+
{
7+
"name": "sETH",
8+
"asset": "ETH",
9+
"subclass": "MultiCollateralSynth"
10+
}
11+
]

publish/deployed/goerli/versions.json

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{}

publish/src/commands/deploy-staking-rewards.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ const deployStakingRewards = async ({
183183
}
184184
}
185185

186-
console.log(gray(`Starting deployment to ${network.toUpperCase()} via Infura...`));
186+
console.log(gray(`Starting deployment to ${network.toUpperCase()}...`));
187187

188188
// Contract dependencies
189189
const rewardsDistributionAddress = deployment.targets['RewardsDistribution'].address;

0 commit comments

Comments
 (0)