-
Notifications
You must be signed in to change notification settings - Fork 4
/
hardhat.config.js
59 lines (54 loc) · 1.41 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
require('dotenv').config();
require("@nomiclabs/hardhat-waffle");
require("hardhat-gas-reporter");
require("@nomiclabs/hardhat-etherscan");
require('@openzeppelin/hardhat-upgrades');
/**
* @type import('hardhat/config').HardhatUserConfig
*/
const INFURA_ROPSTEN_ID = process.env.INFURA_ROPSTEN_ID;
const INFURA_RINKEBY_ID = process.env.INFURA_RINKEBY_ID;
const INFURA_MAINNET_ID = process.env.INFURA_MAINNET_ID;
const ROPSTEN_PRIVATE_KEY = process.env.ROPSTEN_PRIVATE_KEY;
const RINKEBY_PRIVATE_KEY = process.env.RINKEBY_PRIVATE_KEY;
const MAINNET_PRIVATE_KEY = process.env.MAINNET_PRIVATE_KEY;
const ETHERSCAN_API_KEY = process.env.ETHERSCAN_API_KEY;
module.exports = {
solidity: {
compilers: [
{
version: "0.5.2"
},
{
version: "0.8.6",
settings: {
optimizer: {
enabled: true,
runs: 1,
},
},
}
],
},
gasReporter: {
currency: 'USD',
gasPrice: 100
},
networks: {
mainnet: {
url: `https://mainnet.infura.io/v3/${INFURA_MAINNET_ID}`,
accounts: [`${MAINNET_PRIVATE_KEY}`],
},
ropsten: {
url: `https://ropsten.infura.io/v3/${INFURA_ROPSTEN_ID}`,
accounts: [`${ROPSTEN_PRIVATE_KEY}`],
},
rinkeby: {
url: `https://rinkeby.infura.io/v3/${INFURA_RINKEBY_ID}`,
accounts: [`${RINKEBY_PRIVATE_KEY}`],
},
},
etherscan: {
apiKey: ETHERSCAN_API_KEY
}
};