summaryrefslogtreecommitdiffstats
path: root/20.0-beta/fpm/config/redis.config.php
diff options
context:
space:
mode:
authortilosp-bot <git-bot@tilosp.de>2020-08-21 14:00:22 +0000
committertilosp-bot <git-bot@tilosp.de>2020-08-21 14:00:22 +0000
commit4afc60d530c971b50e9eccfccf9e41044423538c (patch)
treed98b370029e81cc372069b0317fae5b54b3638c8 /20.0-beta/fpm/config/redis.config.php
parentbd4cf887a4741837c66ff4b8100a1787ebb6512c (diff)
Run update.sh
Signed-off-by: tilosp-bot <git-bot@tilosp.de>
Diffstat (limited to '20.0-beta/fpm/config/redis.config.php')
-rw-r--r--20.0-beta/fpm/config/redis.config.php17
1 files changed, 17 insertions, 0 deletions
diff --git a/20.0-beta/fpm/config/redis.config.php b/20.0-beta/fpm/config/redis.config.php
new file mode 100644
index 00000000..9429c901
--- /dev/null
+++ b/20.0-beta/fpm/config/redis.config.php
@@ -0,0 +1,17 @@
+<?php
+if (getenv('REDIS_HOST')) {
+ $CONFIG = array (
+ 'memcache.distributed' => '\OC\Memcache\Redis',
+ 'memcache.locking' => '\OC\Memcache\Redis',
+ 'redis' => array(
+ 'host' => getenv('REDIS_HOST'),
+ 'password' => getenv('REDIS_HOST_PASSWORD'),
+ ),
+ );
+
+ if (getenv('REDIS_HOST_PORT') !== false) {
+ $CONFIG['redis']['port'] = (int) getenv('REDIS_HOST_PORT');
+ } elseif (getenv('REDIS_HOST')[0] != '/') {
+ $CONFIG['redis']['port'] = 6379;
+ }
+}