Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MkdirAllPanic ¶
MkdirAllPanic invokes os.MkdirAll but panics if there is an error
func WriteConfigToFile ¶
WriteConfigToFile writes the seed config to file
Types ¶
type Config ¶
type Config struct { ListenAddress string `toml:"laddr" comment:"Address to listen for incoming connections"` ChainID string `toml:"chain_id" comment:"network identifier (todo move to cli flag argument? keeps the config network agnostic)"` LogLevel string `toml:"log_level" comment:"logging level to filter output (\"info\", \"debug\", \"error\" or \"none\")"` NodeKeyFile string `toml:"node_key_file" comment:"path to node_key (relative to tendermint-seed home directory or an absolute path)"` AddrBookFile string `toml:"addr_book_file" comment:"path to address book (relative to tendermint-seed home directory or an absolute path)"` AddrBookStrict bool `toml:"addr_book_strict" comment:"Set true for strict routability rules\n Set false for private or local networks"` MaxNumInboundPeers int `toml:"max_num_inbound_peers" comment:"maximum number of inbound connections"` MaxNumOutboundPeers int `toml:"max_num_outbound_peers" comment:"maximum number of outbound connections"` MaxPacketMsgPayloadSize int `toml:"max_packet_msg_payload_size" comment:"maximum size of a message packet payload, in bytes"` Seeds string `toml:"seeds" comment:"seed nodes we can use to discover peers"` }
Config is a tenderseed configuration
func DefaultConfig ¶
func DefaultConfig() *Config
DefaultConfig returns a seed config initialized with default values
func LoadConfigFromFile ¶
LoadConfigFromFile loads a seed config from a file
func LoadOrGenConfig ¶
LoadOrGenConfig loads a seed config from file if the file exists If the file does not exist, make a default config, write it to the file Return either the loaded config or a default config
Click to show internal directories.
Click to hide internal directories.