summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMeiMei <30769358+mei23@users.noreply.github.com>2019-12-15 03:34:11 +0900
committersyuilo <Syuilotan@yahoo.co.jp>2019-12-15 03:34:11 +0900
commit66165b193562f461330e36da8609fa7f71b465d1 (patch)
treee65db0b379705b0f12e3bb5900be676a423e6e23 /src
parentFix AP inbox Announce (#5641) (diff)
downloadmisskey-66165b193562f461330e36da8609fa7f71b465d1.tar.gz
misskey-66165b193562f461330e36da8609fa7f71b465d1.tar.bz2
misskey-66165b193562f461330e36da8609fa7f71b465d1.zip
Redis prefixにホスト名を使用するように (Resolve #5639) (#5640)
Diffstat (limited to 'src')
-rw-r--r--src/config/load.ts2
-rw-r--r--src/db/postgre.ts2
2 files changed, 3 insertions, 1 deletions
diff --git a/src/config/load.ts b/src/config/load.ts
index efebb8bd03..eea9ed8561 100644
--- a/src/config/load.ts
+++ b/src/config/load.ts
@@ -43,6 +43,8 @@ export default function load() {
if (config.autoAdmin == null) config.autoAdmin = false;
+ if (!config.redis.prefix) config.redis.prefix = mixin.host;
+
return Object.assign(config, mixin);
}
diff --git a/src/db/postgre.ts b/src/db/postgre.ts
index 00476b8774..ad59e86508 100644
--- a/src/db/postgre.ts
+++ b/src/db/postgre.ts
@@ -155,7 +155,7 @@ export function initDb(justBorrow = false, sync = false, log = false) {
host: config.redis.host,
port: config.redis.port,
password: config.redis.pass,
- prefix: config.redis.prefix,
+ prefix: `${config.redis.prefix}:query:`,
db: config.redis.db || 0
}
} : false,