Permalink
Browse files

add `redis_password`

  • Loading branch information...
1 parent b4c49bd commit 4474a93a4fe34a9c6af7d4b311c1d1697c82bdb3 @alsotang alsotang committed Jul 17, 2016
Showing with 4 additions and 0 deletions.
  1. +2 −0 app.js
  2. +1 −0 common/redis.js
  3. +1 −0 config.default.js
View
@@ -97,6 +97,8 @@ app.use(session({
store: new RedisStore({
port: config.redis_port,
host: config.redis_host,
+ db: config.redis_db,
+ pass: config.redis_password,
}),
resave: false,
saveUninitialized: false,
View
@@ -6,6 +6,7 @@ var client = new Redis({
port: config.redis_port,
host: config.redis_host,
db: config.redis_db,
+ password: config.redis_password,
});
client.on('error', function (err) {
View
@@ -41,6 +41,7 @@ var config = {
redis_host: '127.0.0.1',
redis_port: 6379,
redis_db: 0,
+ redis_password: '',
session_secret: 'node_club_secret', // 务必修改
auth_cookie_name: 'node_club',

3 comments on commit 4474a93

@jamiesun

对,是这样子的,我也是这么修改的

@sonong
sonong commented on 4474a93 Jul 23, 2016

redis_password: '',这个密码需要在哪里申请啊?

@Alexis374

@sonong 这是redis的登录密码

Please sign in to comment.