-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
47 lines (47 loc) · 1.34 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
---
version: '3'
services:
mongodb-primary:
image: bitnami/mongodb:3.6.8
ports:
- '27020:27017'
volumes:
- ./db/primary:/bitnami
environment:
- MONGODB_ROOT_PASSWORD=test
- MONGODB_USERNAME=sessionstack
- MONGODB_PASSWORD=test
- MONGODB_DATABASE=sessionstack
- MONGODB_REPLICA_SET_MODE=primary
- MONGODB_REPLICA_SET_NAME=sessionstack-main
- MONGODB_REPLICA_SET_KEY=replicasetkeypass
mongodb-secondary:
image: bitnami/mongodb:3.6.8
depends_on:
- mongodb-primary
ports:
- '27021:27017'
volumes:
- ./db/secondary:/bitnami
environment:
- MONGODB_REPLICA_SET_MODE=secondary
- MONGODB_REPLICA_SET_NAME=sessionstack-main
- MONGODB_REPLICA_SET_KEY=replicasetkeypass
- MONGODB_PRIMARY_HOST=mongodb-primary
- MONGODB_PRIMARY_PORT_NUMBER=27017
- MONGODB_PRIMARY_ROOT_PASSWORD=test
mongodb-arbiter:
image: bitnami/mongodb:3.6.8
depends_on:
- mongodb-primary
ports:
- '27022:27017'
volumes:
- ./db/arbiter:/bitnami
environment:
- MONGODB_REPLICA_SET_MODE=arbiter
- MONGODB_REPLICA_SET_NAME=sessionstack-main
- MONGODB_REPLICA_SET_KEY=replicasetkeypass
- MONGODB_PRIMARY_HOST=mongodb-primary
- MONGODB_PRIMARY_PORT_NUMBER=27017
- MONGODB_PRIMARY_ROOT_PASSWORD=test