-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathhardhat.config.ts
More file actions
113 lines (107 loc) · 2.68 KB
/
hardhat.config.ts
File metadata and controls
113 lines (107 loc) · 2.68 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
// Loading env configs for deploying and public contract source
import { HardhatUserConfig } from "hardhat/config";
import * as dotenv from "dotenv";
dotenv.config();
// All tools for hardhat and smart contracts
import "@nomicfoundation/hardhat-toolbox";
// Openzeppelin upgrade contract feature
import "@openzeppelin/hardhat-upgrades";
// Show contract's size
import "hardhat-contract-sizer";
const config: HardhatUserConfig = {
defaultNetwork: "hardhat",
networks: {
hardhat: {
accounts: { count: 20 },
},
goerli: {
url: "https://eth-goerli.g.alchemy.com/v2/yiaZ5Hg5fTRH46ijJywVW1WF5ltv47xI",
accounts: [process.env.GOERLI_DEPLOY_ACCOUNT!],
chainId: 5,
},
polygonMumbai: {
url: "https://matic-mumbai.chainstacklabs.com",
accounts: [process.env.POLYGON_DEPLOY_ACCOUNT!],
chainId: 80001,
},
bscTestnet: {
url: "https://data-seed-prebsc-1-s3.binance.org:8545/",
accounts: [process.env.BSC_DEPLOY_ACCOUNT!],
chainId: 97,
},
mumbai: {
url: "https://polygon-mumbai.g.alchemy.com/v2/zSybnsuH3h_jqalkVmYv2Xbf-bsc3hlx",
accounts: [process.env.MUMBAI_DEPLOY_ACCOUNT as string]
},
auroraTestnet: {
url: "https://testnet.aurora.dev",
accounts: [process.env.AURORA_TESTNET_DEPLOY_ACCOUNT!]
},
arbitrumGoerli: {
// url: "https://arb-goerli.g.alchemy.com/v2/HvsY1VKZgg_YEJHv_o9GAjjaLmmEO8Xl",
url: "https://goerli-rollup.arbitrum.io/rpc",
accounts: [process.env.ARBITRUM_GOERLI_DEPLOY_ACCOUNT!]
}
},
etherscan: {
apiKey: {
goerli: process.env.GOERLI_SCAN_API_KEY!,
polygonMumbai: process.env.POLYGON_TEST_API_KEY!,
bscTestnet: process.env.BSC_TEST_API_KEY!,
auroraTestnet: process.env.AURORA_TEST_API_KEY!,
arbitrumGoerli: process.env.ARBITRUM_GOERLI_TEST_API_KEY!
},
customChains: [
{
network: "arbitrumGoerli",
chainId: 421613,
urls: {
// apiURL: "https://arb-goerli.g.alchemy.com/v2/HvsY1VKZgg_YEJHv_o9GAjjaLmmEO8Xl",
apiURL: "https://goerli-rollup.arbitrum.io/rpc",
browserURL: "https://goerli.arbiscan.io/"
}
}
]
},
solidity: {
compilers: [
{
version: "0.8.16",
settings: {
optimizer: {
enabled: true,
runs: 200,
},
},
},
],
},
paths: {
sources: "./contracts",
tests: "./test",
cache: "./cache",
artifacts: "./artifacts",
},
contractSizer: {
alphaSort: true,
disambiguatePaths: false,
runOnCompile: false,
strict: true,
},
mocha: {
timeout: 400000,
color: true,
reporter: "mocha-multi-reporters",
reporterOptions: {
configFile: "./mocha-report.json",
},
},
gasReporter: {
enabled: false,
currency: "USD",
token: "BNB",
gasPrice: 30,
coinmarketcap: process.env.COIN_MARKET_API,
},
};
module.exports = config;