17 lines
208 B
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
|
|
}
|