-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
67 lines (65 loc) · 1.68 KB
/
docker-compose.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
version: "3"
services:
my-redis-a:
hostname: redis-master
container_name: redis-master
image: "bitnami/redis"
environment:
- REDIS_REPLICATION_MODE=master
- ALLOW_EMPTY_PASSWORD=yes
ports:
- 5123:6379
my-redis-b:
hostname: redis-replicas-1
container_name: redis-replicas-1
image: "bitnami/redis"
environment:
- REDIS_REPLICATION_MODE=slave
- REDIS_MASTER_HOST=redis-master
- ALLOW_EMPTY_PASSWORD=yes
ports:
- 5124:6379
depends_on:
- my-redis-a
redis-sentinel-1:
container_name: sentinel1
image: 'bitnami/redis-sentinel:latest'
environment:
- REDIS_SENTINEL_DOWN_AFTER_MILLISECONDS=3000
- REDIS_MASTER_HOST=redis-master
- REDIS_MASTER_PORT_NUMBER=6379
- REDIS_MASTER_SET=mymaster
- REDIS_SENTINEL_QUORUM=2
ports:
- 26379:26379
depends_on:
- my-redis-a
- my-redis-b
redis-sentinel-2:
container_name: sentinel2
image: 'bitnami/redis-sentinel:latest'
environment:
- REDIS_SENTINEL_DOWN_AFTER_MILLISECONDS=3000
- REDIS_MASTER_HOST=redis-master
- REDIS_MASTER_PORT_NUMBER=6379
- REDIS_MASTER_SET=mymaster
- REDIS_SENTINEL_QUORUM=2
ports:
- 26380:26379
depends_on:
- my-redis-a
- my-redis-b
redis-sentinel-3:
container_name: sentinel3
image: 'bitnami/redis-sentinel:latest'
environment:
- REDIS_SENTINEL_DOWN_AFTER_MILLISECONDS=3000
- REDIS_MASTER_HOST=redis-master
- REDIS_MASTER_PORT_NUMBER=6379
- REDIS_MASTER_SET=mymaster
- REDIS_SENTINEL_QUORUM=2
ports:
- 26381:26379
depends_on:
- my-redis-a
- my-redis-b