-
Notifications
You must be signed in to change notification settings - Fork 12
/
hardhat.config.js
118 lines (112 loc) · 2.72 KB
/
hardhat.config.js
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
113
114
115
116
117
118
const path = require('path')
require('dotenv').config({
path: path.resolve(__dirname, '.env')
})
require('@nomiclabs/hardhat-ethers')
require('@nomiclabs/hardhat-waffle')
require('@nomiclabs/hardhat-web3')
require('@nomiclabs/hardhat-solhint')
require('hardhat-spdx-license-identifier')
require('hardhat-gas-reporter')
require('solidity-coverage')
require('hardhat-contract-sizer')
require('./tasks/index')
module.exports = {
networks: {
hardhat: {
loggingEnabled: !!(process.env.BUIDLER_LOGGING_ENABLED) || false,
chainId: 1337,
hardfork: 'istanbul'
},
local: {
protocol: 'http',
host: 'localhost',
port: 8545,
loggingEnabled: true,
chainId: 1337,
url: 'http://127.0.0.1:8545'
},
ganache: {
protocol: 'http',
host: 'localhost',
port: 7545,
gas: 800,
network_id: '5777',
url: 'https://mainnet.infura.io/v3/' + process.env.INFURA_PROJECT_ID
},
kovan: {
accounts: {
mnemonic: process.env.DEV_MNEMONIC,
initialIndex: parseInt(process.env.ADDRESS_INDEX),
count: 1
},
url: 'https://kovan.infura.io/v3/' + process.env.INFURA_PROJECT_ID,
network_id: 42
},
mainnet: {
accounts: {
mnemonic: process.env.DEV_MNEMONIC,
initialIndex: parseInt(process.env.ADDRESS_INDEX),
count: 1
},
url: 'https://mainnet.infura.io/v3/' + process.env.INFURA_PROJECT_ID,
network_id: 1
},
goerli: {
accounts: {
mnemonic: process.env.DEV_MNEMONIC,
initialIndex: parseInt(process.env.ADDRESS_INDEX)
},
url: 'https://goerli.infura.io/v3/' + process.env.INFURA_PROJECT_ID,
network_id: 5
},
matic: {
accounts: {
mnemonic: process.env.DEV_MNEMONIC,
initialIndex: parseInt(process.env.ADDRESS_INDEX),
count: 1
},
url: 'https://rpc-mainnet.maticvigil.com/v1/' + process.env.MATIC_VIGIL_ID,
network_id: 137
},
mumbai: {
accounts: {
mnemonic: process.env.DEV_MNEMONIC,
initialIndex: parseInt(process.env.ADDRESS_INDEX),
count: 1
},
url: 'https://rpc-mumbai.maticvigil.com/v1/' + process.env.MATIC_VIGIL_ID,
network_id: 80001,
gasPrice: 1e9,
gasLimit: 2100000
},
coverage: {
url: 'http://localhost:8555'
}
},
solidity: {
compilers: [
{
version: '0.6.12',
settings: {
optimizer: {
enabled: true
}
}
},
{
version: '0.8.4'
}
]
},
mocha: {
timeout: 20000000001
},
gasReporter: {
currency: 'USD',
enabled: !!(process.env.REPORT_GAS)
},
spdxLicenseIdentifier: {
overwrite: true
}
}