You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
19 lines
320 B
19 lines
320 B
|
3 years ago
|
package initviper
|
||
|
|
|
||
|
|
import (
|
||
|
|
"appPlatform/overall"
|
||
|
|
)
|
||
|
|
|
||
|
|
func LoadDatabase() {
|
||
|
|
sqlConfig := overall.CONSTANT_MYSQL
|
||
|
|
RunViper(&sqlConfig, overall.ConfigDatabaseConstant)
|
||
|
|
|
||
|
|
}
|
||
|
|
|
||
|
|
// 加载Redis
|
||
|
|
func LoadRedis() {
|
||
|
|
//读取Redis配置
|
||
|
|
redisConfig := overall.CONSTANT_Redis
|
||
|
|
RunViper(&redisConfig, overall.ConfigRedisConstant)
|
||
|
|
}
|