-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtruffle.js
65 lines (64 loc) · 1.65 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
require("dotenv").config();
const HDWalletProvider = require('@truffle/hdwallet-provider')
const utils = require('web3-utils')
module.exports = {
networks: {
development: {
protocol: "http",
host: "localhost",
port: 8545,
gas: 6500000,
gasPrice: 5e9,
network_id: "*",
},
kovan: {
provider: () => new HDWalletProvider(process.env.PRIVATE_KEY, `https://kovan.infura.io/v3/${process.env.INFURA_APIKEY}`),
network_id: 42,
gas: 4600000,
},
mainnet: {
provider: () => new HDWalletProvider(process.env.PRIVATE_KEY, `https://mainnet.infura.io/v3/${process.env.INFURA_APIKEY}`),
network_id: 1,
gas: 999999,
gasPrice: 130000000000,
},
bsc: {
provider: () => new HDWalletProvider(process.env.PRIVATE_KEY, 'https://bsc-dataseed.binance.org/'),
network_id: 56,
gas: 6000000,
gasPrice: utils.toWei('10', 'gwei'),
// confirmations: 0,
// timeoutBlocks: 200,
skipDryRun: true
},
bsctestnet: {
provider: () => new HDWalletProvider(process.env.PRIVATE_KEY, 'https://data-seed-prebsc-2-s2.binance.org:8545/'),
network_id: 97,
// gas: 6000000,
// gasPrice: utils.toWei('30', 'gwei'),
// confirmations: 0,
// timeoutBlocks: 200,
skipDryRun: true
},
},
compilers: {
solc: {
// version: "0.6.12",
version: "0.8.0",
docker: false,
settings: {
optimizer: {
enabled: true,
runs: 200,
},
evmVersion: "istanbul",
},
},
},
plugins: [
'truffle-plugin-verify'
],
api_keys: {
bscscan: process.env.BSC_SCAN_API
}
}