-
Notifications
You must be signed in to change notification settings - Fork 3
/
truffle.js
50 lines (45 loc) · 1.1 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
49
50
require("babel-register")({
ignore: /node_modules\/(?!zeppelin-solidity)/
});
require("babel-polyfill");
if (process.env.NODE_ENV !== 'production') {
require('dotenv').load();
}
const HDWalletProvider = require("truffle-hdwallet-provider");
const mnemonic = process.env.MNEMONIC
const infura_api = process.env.INFURA_API
const network_id = process.env.NETWORK_ID
module.exports = {
// See <http://truffleframework.com/docs/advanced/configuration>
// to customize your Truffle configuration!
networks: {
'development': {
host: "127.0.0.1",
port: 8545,
network_id: "*" // Match any network id
},
'ganache': {
host: "127.0.0.1",
port: 8545,
network_id: "6000" // Match any network id
},
ropstengeth: {
host: "127.0.0.1",
port: 8545,
network_id: "3"
},
ropsteninfura: {
provider: function() {
return new HDWalletProvider(mnemonic, "https://ropsten.infura.io/" + infura_api)
},
network_id: network_id,
gas:2071238
}
},
solc: {
optimizer: {
enabled: true,
runs: 200
}
}
};