summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndy McCurdy <andy@andymccurdy.com>2020-07-15 15:15:03 -0700
committerAndy McCurdy <andy@andymccurdy.com>2020-07-15 15:15:03 -0700
commit26b611e9732ae655c47f768fa5b8771cb69572f2 (patch)
tree73e14d97a0d5d53cf61932a686d63244b59d3679
parent462fd34a7844a49556f8db5c0af23d81a353c9ed (diff)
downloadredis-py-26b611e9732ae655c47f768fa5b8771cb69572f2.tar.gz
update configs to bind to explicit addresses. configure sentinel
-rw-r--r--docker/master/redis.conf2
-rw-r--r--docker/sentinel_1/Dockerfile4
-rw-r--r--docker/sentinel_1/redis.conf10
-rw-r--r--docker/sentinel_2/Dockerfile4
-rw-r--r--docker/sentinel_2/redis.conf10
-rw-r--r--docker/sentinel_3/Dockerfile4
-rw-r--r--docker/sentinel_3/redis.conf10
-rw-r--r--docker/slave/redis.conf2
8 files changed, 23 insertions, 23 deletions
diff --git a/docker/master/redis.conf b/docker/master/redis.conf
index 271bfaa..ed00766 100644
--- a/docker/master/redis.conf
+++ b/docker/master/redis.conf
@@ -1,3 +1,3 @@
-bind *
+bind master 127.0.0.1
port 6379
save ""
diff --git a/docker/sentinel_1/Dockerfile b/docker/sentinel_1/Dockerfile
index e3c3e7b..3c3f8c2 100644
--- a/docker/sentinel_1/Dockerfile
+++ b/docker/sentinel_1/Dockerfile
@@ -1,7 +1,7 @@
FROM redis-py-base:latest
-COPY redis.conf /etc/conf/redis/redis.conf
+COPY redis.conf /usr/local/etc/redis/redis.conf
EXPOSE 26379
-CMD redis-server
+CMD [ "redis-sentinel", "/usr/local/etc/redis/redis.conf" ]
diff --git a/docker/sentinel_1/redis.conf b/docker/sentinel_1/redis.conf
index d12979f..fc9aa68 100644
--- a/docker/sentinel_1/redis.conf
+++ b/docker/sentinel_1/redis.conf
@@ -1,7 +1,7 @@
-pidfile /var/run/sentinel-1.pid
+bind sentinel_1 127.0.0.1
port 26379
-daemonize yes
-logfile /var/log/redis-sentinel-1
-# short timeout for sentinel tests
-sentinel down-after-milliseconds mymaster 500
+sentinel monitor redis-py-test master 6379 2
+sentinel down-after-milliseconds redis-py-test 5000
+sentinel failover-timeout redis-py-test 60000
+sentinel parallel-syncs redis-py-test 1
diff --git a/docker/sentinel_2/Dockerfile b/docker/sentinel_2/Dockerfile
index cd59777..dc3c332 100644
--- a/docker/sentinel_2/Dockerfile
+++ b/docker/sentinel_2/Dockerfile
@@ -1,7 +1,7 @@
FROM redis-py-base:latest
-COPY redis.conf /etc/conf/redis/redis.conf
+COPY redis.conf /usr/local/etc/redis/redis.conf
EXPOSE 26380
-CMD redis-server
+CMD [ "redis-sentinel", "/usr/local/etc/redis/redis.conf" ]
diff --git a/docker/sentinel_2/redis.conf b/docker/sentinel_2/redis.conf
index 9ab8934..264443c 100644
--- a/docker/sentinel_2/redis.conf
+++ b/docker/sentinel_2/redis.conf
@@ -1,7 +1,7 @@
-pidfile /var/run/sentinel-2.pid
+bind sentinel_2 127.0.0.1
port 26380
-daemonize yes
-logfile /var/log/redis-sentinel-2
-# short timeout for sentinel tests
-sentinel down-after-milliseconds mymaster 500
+sentinel monitor redis-py-test master 6379 2
+sentinel down-after-milliseconds redis-py-test 5000
+sentinel failover-timeout redis-py-test 60000
+sentinel parallel-syncs redis-py-test 1
diff --git a/docker/sentinel_3/Dockerfile b/docker/sentinel_3/Dockerfile
index 2e81a15..f0d48c9 100644
--- a/docker/sentinel_3/Dockerfile
+++ b/docker/sentinel_3/Dockerfile
@@ -1,7 +1,7 @@
FROM redis-py-base:latest
-COPY redis.conf /etc/conf/redis/redis.conf
+COPY redis.conf /usr/local/etc/redis/redis.conf
EXPOSE 26381
-CMD redis-server
+CMD [ "redis-sentinel", "/usr/local/etc/redis/redis.conf" ]
diff --git a/docker/sentinel_3/redis.conf b/docker/sentinel_3/redis.conf
index b971b2f..b0827f1 100644
--- a/docker/sentinel_3/redis.conf
+++ b/docker/sentinel_3/redis.conf
@@ -1,7 +1,7 @@
-pidfile /var/run/sentinel-3.pid
+bind sentinel_3 127.0.0.1
port 26381
-daemonize yes
-logfile /var/log/redis-sentinel-3
-# short timeout for sentinel tests
-sentinel down-after-milliseconds mymaster 500
+sentinel monitor redis-py-test master 6379 2
+sentinel down-after-milliseconds redis-py-test 5000
+sentinel failover-timeout redis-py-test 60000
+sentinel parallel-syncs redis-py-test 1
diff --git a/docker/slave/redis.conf b/docker/slave/redis.conf
index e2d8aba..629ac70 100644
--- a/docker/slave/redis.conf
+++ b/docker/slave/redis.conf
@@ -1,4 +1,4 @@
-bind *
+bind slave 127.0.0.1
port 6380
save ""
slaveof master 6379