2021-03-23 16:00:07 +07:00
|
|
|
package params
|
|
|
|
|
|
|
|
import (
|
2021-03-26 21:05:42 +03:00
|
|
|
"crypto/ecdsa"
|
2021-03-23 16:00:07 +07:00
|
|
|
"math/big"
|
|
|
|
"time"
|
|
|
|
|
2021-05-21 01:25:53 +07:00
|
|
|
"github.com/ledgerwatch/erigon/common"
|
|
|
|
"github.com/ledgerwatch/erigon/common/hexutil"
|
2021-03-23 16:00:07 +07:00
|
|
|
)
|
|
|
|
|
|
|
|
// MiningConfig is the configuration parameters of mining.
|
|
|
|
type MiningConfig struct {
|
2022-01-04 18:37:36 +01:00
|
|
|
Enabled bool
|
|
|
|
EnabledPOS bool
|
|
|
|
Noverify bool // Disable remote mining solution verification(only useful in ethash).
|
|
|
|
Etherbase common.Address `toml:",omitempty"` // Public address for block mining rewards
|
|
|
|
SigKey *ecdsa.PrivateKey // ECDSA private key for signing blocks
|
|
|
|
Notify []string `toml:",omitempty"` // HTTP URL list to be notified of new work packages(only useful in ethash).
|
|
|
|
ExtraData hexutil.Bytes `toml:",omitempty"` // Block extra data set by the miner
|
2022-01-05 10:36:24 +01:00
|
|
|
GasLimit uint64 // Target gas limit for mined blocks.
|
2022-01-04 18:37:36 +01:00
|
|
|
GasPrice *big.Int // Minimum gas price for mining a transaction
|
|
|
|
Recommit time.Duration // The time interval for miner to re-create mining work.
|
2021-03-23 16:00:07 +07:00
|
|
|
}
|