forked from kytos/end-to-end-tests
-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathdocker-compose.local.yml
44 lines (44 loc) · 1.17 KB
/
docker-compose.local.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
version: '2.1'
services:
mongo-setup:
container_name: mongo-test-rs-init
image: mongo:7.0
restart: on-failure
volumes:
- ./scripts:/scripts
entrypoint: ["scripts/rs-init.sh"]
environment:
MONGO_INITDB_ROOT_USERNAME: root_user
MONGO_INITDB_ROOT_PASSWORD: root_pw
MONGO_USERNAME: napp_user
MONGO_PASSWORD: napp_pw
MONGO_DBNAME: napps
MONGO_NODES: mongo1LT:27037 mongo2LT:27038 mongo3LT:27039
depends_on:
- mongo1LT
- mongo2LT
- mongo3LT
mongo1LT:
container_name: mongo1LT
image: mongo:7.0
ports:
- 27037:27037
restart: always
entrypoint: [ "/usr/bin/mongod", "--bind_ip_all", "--replSet", "rs0", "--port", "27037" ]
depends_on:
- mongo2LT
- mongo3LT
mongo2LT:
container_name: mongo2LT
image: mongo:7.0
ports:
- 27038:27038
restart: always
entrypoint: [ "/usr/bin/mongod", "--bind_ip_all", "--replSet", "rs0", "--port", "27038" ]
mongo3LT:
container_name: mongo3LT
image: mongo:7.0
ports:
- 27039:27039
restart: always
entrypoint: [ "/usr/bin/mongod", "--bind_ip_all", "--replSet", "rs0", "--port", "27039" ]