-
Notifications
You must be signed in to change notification settings - Fork 5
/
truffle.js
93 lines (89 loc) · 2.76 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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
var HDWalletProvider = require('truffle-hdwallet-provider')
const LedgerWalletProvider = require('@deconet/truffle-ledger-provider')
const ledgerOptions = {
networkId: 1,
path: "44'/60'/0'/0",
askConfirm: false,
accountsLength: 1,
accountsOffset: 0,
}
// matching address is 0x648d692e5c507c233d0f9d9fea062429003b3144
let mnemonic = process.env.DECONET_BLOCKCHAIN_ROPSTEN_MNEMONIC
module.exports = {
networks: {
development: {
host: '127.0.0.1',
port: 8545,
network_id: '*' // Match any network id
},
ropsten: {
provider: /*function() {
return new LedgerWalletProvider(ledgerOptions, 'https://ropsten.infura.io/JTdaA5dJvlwfCfdgT5Cm')
},*/
function () {
// remote infura
// return new HDWalletProvider(mnemonic, 'https://ropsten.infura.io/JTdaA5dJvlwfCfdgT5Cm')
// local GETH which supports debug
// return new HDWalletProvider(mnemonic, 'http://127.0.0.1:8549')
// remote GETH
//return new HDWalletProvider(mnemonic, process.env.DECONET_ROPSTEN_NODE_URL)
// geonda.io
return new HDWalletProvider(mnemonic, 'http://35.170.208.0:8545')
},
network_id: 3,
gas: 4700000,
gasPrice: 10000000000 // 10 gwei
},
mainnet: {
provider: function() {
// return new LedgerWalletProvider(ledgerOptions, 'http://18.208.64.51:8545')
// return new LedgerWalletProvider(ledgerOptions, "https://rapidly-renewed-buzzard.quiknode.io")
//return new LedgerWalletProvider(ledgerOptions, "https://mainnet.infura.io/JTdaA5dJvlwfCfdgT5Cm")
return new HDWalletProvider(mnemonic, "https://mainnet.infura.io/JTdaA5dJvlwfCfdgT5Cm")
},
network_id: 1,
gas: 7000000,
gasPrice: 5000000000 // 5 gwei
},
rinkeby: {
provider:
/* function() {
return new LedgerWalletProvider(ledgerOptions, 'https://rinkeby.infura.io/JTdaA5dJvlwfCfdgT5Cm')
}, */
function () {
return new HDWalletProvider(mnemonic, 'https://rinkeby.infura.io/JTdaA5dJvlwfCfdgT5Cm')
},
network_id: 4,
gas: 4700000,
gasPrice: 3000000000 // 3 gwei
},
kovan: {
provider:
/*function() {
return new LedgerWalletProvider(ledgerOptions, 'https://kovan.infura.io/JTdaA5dJvlwfCfdgT5Cm')
},*/
function () {
return new HDWalletProvider(mnemonic, 'https://rinkeby.infura.io/JTdaA5dJvlwfCfdgT5Cm')
},
network_id: 42,
gas: 4700000,
gasPrice: 1000000000 // 1 gwei
},
coverage: {
host: "127.0.0.1",
network_id: "*",
port: 8997,
gas: 0xfffffffffff,
gasPrice: 0x01
}
},
compilers: {
solc: {
version: "0.4.25",
optimizer: {
enabled: true,
runs: 200,
}
}
}
}