mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-06-19 21:31:37 +00:00
fixed only three MNs making block when --XDC testnet flag enable
This commit is contained in:
parent
01583f3548
commit
ece14048a5
4 changed files with 13 additions and 1 deletions
|
|
@ -36,6 +36,7 @@ import (
|
|||
"github.com/ethereum/go-ethereum/params"
|
||||
whisper "github.com/ethereum/go-ethereum/whisper/whisperv6"
|
||||
"github.com/naoina/toml"
|
||||
"github.com/ethereum/go-ethereum/common"
|
||||
)
|
||||
|
||||
var (
|
||||
|
|
@ -151,6 +152,10 @@ func makeConfigNode(ctx *cli.Context) (*node.Node, XDCConfig) {
|
|||
ctx.Set(utils.NATFlag.Name, cfg.NAT)
|
||||
}
|
||||
|
||||
// Check testnet is enable.
|
||||
if ctx.GlobalBool(utils.XDCTestnetFlag.Name) {
|
||||
common.IsTestnet = true
|
||||
}
|
||||
// read passwords from enviroment
|
||||
passwords := []string{}
|
||||
for _, env := range cfg.Account.Passwords {
|
||||
|
|
|
|||
|
|
@ -109,6 +109,7 @@ var (
|
|||
//utils.TestnetFlag,
|
||||
//utils.RinkebyFlag,
|
||||
//utils.VMEnableDebugFlag,
|
||||
utils.XDCTestnetFlag,
|
||||
utils.NetworkIdFlag,
|
||||
utils.RPCCORSDomainFlag,
|
||||
utils.RPCVirtualHostsFlag,
|
||||
|
|
|
|||
|
|
@ -137,6 +137,10 @@ var (
|
|||
Name: "testnet",
|
||||
Usage: "Ropsten network: pre-configured proof-of-work test network",
|
||||
}
|
||||
XDCTestnetFlag = cli.BoolFlag{
|
||||
Name: "XDC-testnet",
|
||||
Usage: "XDC test network",
|
||||
}
|
||||
RinkebyFlag = cli.BoolFlag{
|
||||
Name: "rinkeby",
|
||||
Usage: "Rinkeby network: pre-configured proof-of-authority test network",
|
||||
|
|
|
|||
|
|
@ -15,4 +15,6 @@ const (
|
|||
BlocksPerYear = uint64(15768000)
|
||||
LimitThresholdNonceInQueue = 10
|
||||
MinGasPrice = 2500
|
||||
)
|
||||
)
|
||||
|
||||
var IsTestnet bool = false
|
||||
Loading…
Reference in a new issue