Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Node NodeConfig `mapstructure:"node"` DB DBConfig `mapstructure:"database"` Web WebConfig `mapstructure:"web"` Market MarketConfig `mapstructure:"market"` }
Config wraps all config.
func ParseConfig ¶
func ParseConfig() *Config
ParseConfig attempts to read and parse config.yaml from the given path An error reading or parsing the config results in a panic.
type DBConfig ¶
type DBConfig struct { Host string `mapstructure:"host"` Port string `mapstructure:"port"` User string `mapstructure:"user"` Password string `mapstructure:"password"` Database string `mapstructure:"dbname"` }
DBConfig wraps all required parameters for database connection.
type MarketConfig ¶
type MarketConfig struct {
CoinGeckoEndpoint string `mapstructure:"coingecko_endpoint"`
}
MarketConfig wraps all required params for market endpoints.
type NodeConfig ¶
type NodeConfig struct { RPCNode string `mapstructure:"rpc_node"` ExchangeAPIEndpoint string `mapstructure:"exchange_api_endpoint"` ChainID string `mapstructure:"chain_id"` }
NodeConfig wraps all node endpoints that are used in this project.
Click to show internal directories.
Click to hide internal directories.