Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct { Database DBConfig `mapstructure:"database"` HTTP HTTPServerConfig `mapstructure:"http"` }
Config represents the top level config.
func LoadConfig ¶
LoadConfig sets up viper and returns the application configuration
type DBConfig ¶
type DBConfig struct { Host string `mapstructure:"host"` Port int `mapstructure:"port"` Name string `mapstructure:"name"` Username string `mapstructure:"user"` Password string `mapstructure:"password"` }
DBConfig contains the fields needed to connect to the RDBMS.
type HTTPServerConfig ¶
type HTTPServerConfig struct {
Port int `mapstructure:"port"`
}
HTTPServerConfig contains the config for HTTP server
Click to show internal directories.
Click to hide internal directories.