liuxiaolong
2019-08-31 c7a8ae9004aab2ae40be3d4b12cd31d184da1549
extend/config/config.go
@@ -69,6 +69,10 @@
var DBconf = &database{}
type facedetect struct {
   Url string `mapstructure:"url"`
}
type dbpersoncompare struct {
   Url string `mapstructure:"url"`
}
@@ -81,6 +85,7 @@
var EsCompServerInfo = &espersoncompare{}
var FaceDetectSet = &facedetect{}
// Init is an exported method that takes the environment starts the viper
// (external lib) and returns the configuration struct.
@@ -100,6 +105,7 @@
   viper.UnmarshalKey("database", DBconf)
   viper.UnmarshalKey("weedfs", WeedFs)
   viper.UnmarshalKey("sopath",SoPath)
   viper.UnmarshalKey("facedetect", FaceDetectSet)
   viper.UnmarshalKey("dbpersoncompare",DbPersonCompInfo)
   viper.UnmarshalKey("espersoncompare", EsCompServerInfo)
}