config

package
v1.2.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 16, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewConfig

func NewConfig() (map[string]Config, error)

NewConfig reads the Suimon configuration files from the directory specified by the SUIMON_CONFIG_PATH environment variable or the default directory if the environment variable is not set, and returns a map of Config objects with the file name segments as the keys.

Types

type Config

type Config struct {
	IPLookup struct {
		AccessToken string `yaml:"access-token"`
	} `yaml:"ip-lookup"`
	ReferenceRPC []string `yaml:"reference-rpc"`
	FullNodes    []struct {
		JSONRPCAddress string `yaml:"json-rpc-address"`
		MetricsAddress string `yaml:"metrics-address"`
	} `yaml:"full-nodes"`
	Validators []struct {
		MetricsAddress string `yaml:"metrics-address"`
	} `yaml:"validators"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL