updated readme. made redis optional in dev
This commit is contained in:
parent
663023a204
commit
131a8b5564
4 changed files with 29 additions and 5 deletions
|
@ -10,7 +10,12 @@ const mozlog = require('./log');
|
|||
|
||||
const log = mozlog('send.storage');
|
||||
|
||||
const redis = require('redis');
|
||||
const redis_lib =
|
||||
config.env === 'development' && config.redis_host === 'localhost'
|
||||
? 'redis-mock'
|
||||
: 'redis';
|
||||
|
||||
const redis = require(redis_lib);
|
||||
const redis_client = redis.createClient({
|
||||
host: config.redis_host,
|
||||
connect_timeout: 10000
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue