-
Notifications
You must be signed in to change notification settings - Fork 4
/
truffle-config.js
49 lines (48 loc) · 1.34 KB
/
truffle-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
require("ts-node").register({files: true});
const HDWalletProvider = require("@truffle/hdwallet-provider");
require('dotenv').config();
const Web3 = require("web3");
const web3 = new Web3();
module.exports = {
plugins: ['truffle-plugin-verify', "truffle-contract-size"],
api_keys: {
etherscan: process.env.ETHERSCAN_API_KEY,
},
networks: {
development: {
host: "127.0.0.1",
port: 8545,
network_id: "*"
},
rinkeby: {
provider: function() {
return new HDWalletProvider(process.env.TESTNET_PRIVATE_KEY, `https://rinkeby.infura.io/v3/${process.env.INFURA_ACCESS_TOKEN}`);
},
network_id: 4,
// gas: 30000000, //from ganache-cli output
// gasPrice: web3.utils.toWei('1', 'gwei')
},
ropsten: {
provider: function() {
return new HDWalletProvider(process.env.TESTNET_PRIVATE_KEY, `https://ropsten.infura.io/v3/${process.env.INFURA_ACCESS_TOKEN}`);
},
network_id: 3,
// gas: 30000000, //from ganache-cli output
gasPrice: web3.utils.toWei('1', 'gwei')
}
},
mocha: {
//reporter: 'eth-gas-reporter',
},
compilers: {
solc: {
version: "0.8.13",
settings: { // See the solidity docs for advice about optimization and evmVersion
optimizer: {
enabled: true,
runs: 1000
}
}
}
}
};