Merge branch 'openimsdk:main' into env2

This commit is contained in:
Brabem 2023-12-29 15:59:48 +08:00 committed by GitHub
commit b7bd7484dc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -74,6 +74,10 @@ func buildMongoURI() string {
return uri return uri
} }
if config.Config.Mongo.Uri != "" {
return config.Config.Mongo.Uri
}
username := os.Getenv("MONGO_USERNAME") username := os.Getenv("MONGO_USERNAME")
password := os.Getenv("MONGO_PASSWORD") password := os.Getenv("MONGO_PASSWORD")
address := os.Getenv("MONGO_ADDRESS") address := os.Getenv("MONGO_ADDRESS")