track/pkg/config/config.go

17 lines
208 B
Go

package config
import "os"
type Config struct {
DBPath string
Listen string
}
func New() *Config {
cfg := new(Config)
cfg.DBPath = os.Getenv("DB_PATH")
cfg.Listen = os.Getenv("LISTEN")
return cfg
}