增加了redis的数据库
This commit is contained in:
+1
-1
@@ -14,7 +14,7 @@ func Redis() {
|
||||
global.Redis = redis.NewClient(&redis.Options{
|
||||
Addr: config.C.Redis.Host + ":" + strconv.Itoa(config.C.Redis.Port),
|
||||
Password: config.C.Redis.Password, // no password set
|
||||
DB: 0, // use default DB
|
||||
DB: config.C.Redis.Db, // use default DB
|
||||
PoolSize: config.C.Redis.PoolSize,
|
||||
})
|
||||
_, err := global.Redis.Ping(context.Background()).Result()
|
||||
|
||||
Reference in New Issue
Block a user