mirror of
https://github.com/MatthewL246/pretendo-docker.git
synced 2026-08-26 12:56:07 -05:00
Configure Juxtaposition with Redis
This commit is contained in:
@@ -296,6 +296,7 @@ services:
|
||||
depends_on:
|
||||
- account
|
||||
- mongodb
|
||||
- redis
|
||||
- friends
|
||||
restart: unless-stopped
|
||||
ports:
|
||||
|
||||
@@ -46,5 +46,9 @@ module.exports = JSON.parse(
|
||||
secret: process.env.JUXT_CONFIG_AWS_SPACES_SECRET,
|
||||
},
|
||||
},
|
||||
redis: {
|
||||
host: process.env.JUXT_CONFIG_REDIS_HOST,
|
||||
port: process.env.JUXT_CONFIG_REDIS_PORT,
|
||||
},
|
||||
})
|
||||
);
|
||||
|
||||
@@ -11,3 +11,5 @@ JUXT_CONFIG_WHITELIST=1|http,mii.olv.pretendo.cc,,2|1|https,mii.olv.pretendo.cc,
|
||||
JUXT_CONFIG_POST_LIMIT=20
|
||||
JUXT_CONFIG_AWS_SPACES_ENDPOINT=http://minio.pretendo.cc
|
||||
JUXT_CONFIG_AWS_SPACES_KEY=minio_pretendo
|
||||
JUXT_CONFIG_REDIS_HOST=redis
|
||||
JUXT_CONFIG_REDIS_PORT=6379
|
||||
|
||||
13
patches/juxtaposition-ui/redis-create-client-with-url.patch
Normal file
13
patches/juxtaposition-ui/redis-create-client-with-url.patch
Normal file
@@ -0,0 +1,13 @@
|
||||
diff --git i/src/redisCache.js w/src/redisCache.js
|
||||
index b4f3b7a..cabe595 100644
|
||||
--- i/src/redisCache.js
|
||||
+++ w/src/redisCache.js
|
||||
@@ -5,7 +5,7 @@ const logger = require('./logger');
|
||||
const config = require('../config.json');
|
||||
const { host, port } = config.redis;
|
||||
|
||||
-const redisClient = redis.createClient({ host, port });
|
||||
+const redisClient = redis.createClient({ url: `redis://${host}:${port}` });
|
||||
|
||||
redisClient.on('error', (error) => {
|
||||
logger.error(error);
|
||||
Reference in New Issue
Block a user