-
Notifications
You must be signed in to change notification settings - Fork 5
/
truffle.js
48 lines (46 loc) · 1.13 KB
/
truffle.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
var HDWalletProvider = require("truffle-hdwallet-provider");
var mnemonic = require('fs').readFileSync('./pass').toString();
var infuraKey = "kt4dd4NLAwM43QWBU7Qg";
const defaultGas = 4e6;
const defaultGasPrice = 5e9;
module.exports = {
networks: {
development: {
host: "localhost",
port: 8545,
gas: defaultGas,
gasPrice: defaultGasPrice,
network_id: "*"
},
ropsten:{
provider: function() {
return new HDWalletProvider(mnemonic, "https://ropsten.infura.io/" + infuraKey)
},
network_id: 3,
gas: defaultGas,
gasPrice: defaultGasPrice
},
rinkeby: {
provider: function() {
return new HDWalletProvider(mnemonic, "https://rinkeby.infura.io/" + infuraKey)
},
network_id: 4,
gas: defaultGas,
gasPrice: defaultGasPrice
},
main: {
provider: function() {
return new HDWalletProvider(mnemonic, "https://mainnet.infura.io/" + infuraKey)
},
network_id: 1,
gas: defaultGas,
gasPrice: defaultGasPrice
}
},
solc: {
optimizer: {
enabled: true,
runs: 200
}
}
};