package config import "github.com/spf13/viper" func init() { viper.SetConfigName("config") viper.AddConfigPath(".") viper.SetConfigType("yaml") viper.AutomaticEnv() viper.ReadInConfig() } func GetConfig() *viper.Viper { return viper.GetViper() }