Explorar o código

update config

DevYK %!s(int64=3) %!d(string=hai) anos
pai
achega
09f994d26d
Modificáronse 1 ficheiros con 6 adicións e 11 borrados
  1. 6 11
      model/redis_db.js

+ 6 - 11
model/redis_db.js

@@ -18,21 +18,16 @@ if (config.build_config.open_test == 0) {
 // username: username,
 // password: password,
 console.log('host , post', host, port)
-var REDIS_INSTANCE = new Redis({
+
+const opts = {
   port: port,
   host: host,
-  username: username,
-  password: password,
+  // username: username,
+  // password: password,
   connectTimeout: 10000,
-});
+}
 
-// var REDIS_INSTANCE = new Redis.Cluster([
-//   {
-//     port: port,
-//     password: password,
-//     host: host,
-//   },
-// ]);
+var REDIS_INSTANCE = new Redis(opts);
 
 REDIS_INSTANCE.on('connect', () => {
   console.log('connected to redis')