-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtruffle-config.js
50 lines (46 loc) · 1.44 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
50
// Allows us to use ES6 in our migrations and tests.
require('babel-register')
let HDWalletProvider = require("truffle-hdwallet-provider");
// https://faucet.metamask.io/ - Top up your metamask wallet
/**
* You will require a mnemomic and an Infura API Key of your own for this configuration.
* For testing Ropsten seems to be working most of the time.
*/
let mnemonic = "<your seed words>";
let infuraAPIKey = "<your-infura-api-key>";
module.exports = {
networks: {
// Main - Production : WARNING this will use real Ether and cost you money to deploy contracts.
mainnet: {
provider: function() {
return new HDWalletProvider(mnemonic, "https://mainnet.infura.io/" + infuraAPIKey)
},
network_id: 3,
gas: 4600000
},
// Rinkeby - Production : WARNING this will use real Ether and cost you money to deploy contracts.
rinkeby: {
provider: function() {
return new HDWalletProvider(mnemonic, "https://rinkeby.infura.io/" + infuraAPIKey)
},
network_id: 3,
gas: 4600000
},
// Kovan
kovan: {
provider: function() {
return new HDWalletProvider(mnemonic, "https://kovan.infura.io/" + infuraAPIKey)
},
network_id: 3,
gas: 4600000
},
// Ropsten
ropsten: {
provider: function() {
return new HDWalletProvider(mnemonic, "https://ropsten.infura.io/" + infuraAPIKey)
},
network_id: 3,
gas: 4600000
}
}
};