-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathdocker-compose.cnf.yml
59 lines (57 loc) · 2.18 KB
/
docker-compose.cnf.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
version: '3'
services:
mongo-cnf-2:
container_name: "mongo-cnf-2"
image: lili/mongo:1.0
ports:
- "37019:27017"
command: /home/admin/app/mongo/mongodb/bin/mongod --replSet cnf-serv --configsvr --port 27017 --dbpath /home/admin/data/config --logpath /home/admin/logs/config.log --bind_ip 0.0.0.0
volumes:
- "/tmp/docker/data/mongo/37019:/home/admin/data/config"
- "/tmp/docker/logs/mongo/37019:/home/admin/logs"
restart: always
mongo-cnf-3:
container_name: "mongo-cnf-3"
image: lili/mongo:1.0
ports:
- "27019:27017"
command: /home/admin/app/mongo/mongodb/bin/mongod --replSet cnf-serv --configsvr --port 27017 --dbpath /home/admin/data/config --logpath /home/admin/logs/config.log --bind_ip 0.0.0.0
volumes:
- "/tmp/docker/data/mongo/27019:/home/admin/data/config"
- "/tmp/docker/logs/mongo/27019:/home/admin/logs"
restart: always
mongo-cnf-1:
container_name: "mongo-cnf-1"
image: lili/mongo:1.0
ports:
- "47019:27017"
command: /home/admin/app/mongo/mongodb/bin/mongod --replSet cnf-serv --configsvr --port 27017 --dbpath /home/admin/data/config --logpath /home/admin/logs/config.log --bind_ip 0.0.0.0
volumes:
- "/tmp/docker/data/mongo/47019:/home/admin/data/config"
- "/tmp/docker/logs/mongo/47019:/home/admin/logs"
links:
- mongo-cnf-2:mongo-cnf-2
- mongo-cnf-3:mongo-cnf-3
restart: always
mongo-cnf-setup:
container_name: "mongo-cnf-setup"
image: lili/mongo:1.0
depends_on:
- "mongo-cnf-1"
- "mongo-cnf-2"
- "mongo-cnf-3"
links:
- mongo-cnf-1:mongo-cnf-1
- mongo-cnf-2:mongo-cnf-2
- mongo-cnf-3:mongo-cnf-3
environment:
- MONGO1=mongo-cnf-1
- MONGO2=mongo-cnf-2
- MONGO3=mongo-cnf-3
- RS=cnf-serv
- PORT=27017
entrypoint: [ "/home/admin/app/mongo/setup-cnf.sh" ]
networks:
default:
external:
name: lili-bridge-network