mirror of
https://github.com/tendermint/tendermint.git
synced 2026-09-19 22:44:24 +00:00
distinguish between seeds and manual peers in the config/flags
- we only use seeds if we can’t connect to peers in the addrbook. - we always connect to nodes given in config/flags Refs #864
This commit is contained in:
+6
-1
@@ -170,7 +170,7 @@ type RPCConfig struct {
|
||||
// NOTE: This server only supports /broadcast_tx_commit
|
||||
GRPCListenAddress string `mapstructure:"grpc_laddr"`
|
||||
|
||||
// Activate unsafe RPC commands like /dial_seeds and /unsafe_flush_mempool
|
||||
// Activate unsafe RPC commands like /dial_manual_peers and /unsafe_flush_mempool
|
||||
Unsafe bool `mapstructure:"unsafe"`
|
||||
}
|
||||
|
||||
@@ -203,8 +203,13 @@ type P2PConfig struct {
|
||||
ListenAddress string `mapstructure:"laddr"`
|
||||
|
||||
// Comma separated list of seed nodes to connect to
|
||||
// We only use these if we can’t connect to peers in the addrbook
|
||||
Seeds string `mapstructure:"seeds"`
|
||||
|
||||
// Comma separated list of manual peers to connect to
|
||||
// We always connect to these
|
||||
ManualPeers string `mapstructure:"manual_peers"`
|
||||
|
||||
// Skip UPNP port forwarding
|
||||
SkipUPNP bool `mapstructure:"skip_upnp"`
|
||||
|
||||
|
||||
@@ -42,6 +42,7 @@ laddr = "tcp://0.0.0.0:46657"
|
||||
[p2p]
|
||||
laddr = "tcp://0.0.0.0:46656"
|
||||
seeds = ""
|
||||
manual_peers = ""
|
||||
`
|
||||
|
||||
func defaultConfig(moniker string) string {
|
||||
@@ -106,6 +107,7 @@ laddr = "tcp://0.0.0.0:36657"
|
||||
[p2p]
|
||||
laddr = "tcp://0.0.0.0:36656"
|
||||
seeds = ""
|
||||
manual_peers = ""
|
||||
`
|
||||
|
||||
func testConfig(moniker string) (testConfig string) {
|
||||
|
||||
Reference in New Issue
Block a user