Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitConfig ¶
func InitConfig() error
Types ¶
type Config ¶
type Config struct { Server struct { Port string `yaml:"port" envconfig:"SERVER_PORT"` Secret string `yaml:"secret" envconfig:"SERVER_SECRET"` TokenLifespan int32 `yaml:"tokenLifespan" envconfig:"SERVER_TOKEN_LIFESPAN"` } `yaml:"server"` Database struct { Username string `yaml:"username" envconfig:"DB_USERNAME"` Password string `yaml:"password" envconfig:"DB_PASSWORD"` Host string `yaml:"host" envconfig:"DB_HOST"` Port string `yaml:"port" envconfig:"DB_PORT"` } `yaml:"database"` }
var Cfg Config
Click to show internal directories.
Click to hide internal directories.