]> cat aescling's git repositories - mastodon.git/commitdiff
Change streaming server to treat blank redis password as password-less auth (#14135)
authorThibG <thib@sitedethib.com>
Wed, 24 Jun 2020 20:25:23 +0000 (22:25 +0200)
committerGitHub <noreply@github.com>
Wed, 24 Jun 2020 20:25:23 +0000 (22:25 +0200)
Fixes #14131

Our `mastodon:setup` task defaults to a blank password rather than the
absence of password, but some versions of Redis reject blank password
authentication when authentication is possible without a password.

The Ruby code only uses the Redis password when it's not blank, so
do the same for the node.js part.

streaming/index.js

index d7b1df81f6ba15982d65bd2879af545b8a84d537..39e70c1ba7ef9ad1a1760b07616fe60c22773710 100644 (file)
@@ -118,7 +118,7 @@ const startWorker = (workerId) => {
     host:     process.env.REDIS_HOST     || '127.0.0.1',
     port:     process.env.REDIS_PORT     || 6379,
     db:       process.env.REDIS_DB       || 0,
-    password: process.env.REDIS_PASSWORD,
+    password: process.env.REDIS_PASSWORD || undefined,
   };
 
   if (redisNamespace) {