示例#1
0
文件: lifecycle.go 项目: snikch/api
func newConf() *goose.DBConf {
	file := config.String("BASE_DIR") + config.String("DBCONF_DIR", "db")
	conf, err := goose.NewDBConf(file, "test", "")
	if err != nil {
		log.WithError(fail.Trace(err)).WithField("filename", file).Fatal("Could not create new conf")
	}
	return conf
}
示例#2
0
文件: main.go 项目: snikch/goose
// helper to create a DBConf from the given flags
func dbConfFromFlags() (dbconf *goose.DBConf, err error) {
	return goose.NewDBConf(*flagPath, *flagEnv, *flagPgSchema)
}