-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathdocker-compose.yml
53 lines (49 loc) · 1.47 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
version: '3.1'
services:
postgres:
image: postgres:latest
environment:
- POSTGRES_PASSWORD=singlestone
- POSTGRES_USER=singlestone
- POSTGRES_DB=singlestone
ports:
- 5432:5432
volumes:
- ./config_pg/init.sql:/docker-entrypoint-initdb.d/init.sql
- ./config_pg/students.csv:/tmp/students.csv
adminer:
image: adminer:latest
ports:
- 8080:8080
mongo:
image: mongo:latest
environment:
- MONGO_INITDB_DATABASE=singlestone
- MONGO_INITDB_ROOT_USERNAME=singlestone
- MONGO_INITDB_ROOT_PASSWORD=singlestone
volumes:
- ./config_mongo/teachers.json:/tmp/teachers.json
ports:
- 27017-27019:27017-27019
mongo-seed:
image: mongo:latest
command: mongoimport --db singlestone --collection teachers --file /tmp/teachers.json -u singlestone -p singlestone --authenticationDatabase admin -h mongo
volumes:
- ./config_mongo/teachers.json:/tmp/teachers.json
depends_on:
- mongo
mongo-express:
image: mongo-express:latest
ports:
- 8081:8081
environment:
- ME_CONFIG_MONGODB_SERVER=mongo
- ME_CONFIG_MONGODB_PORT=27017
- ME_CONFIG_MONGODB_ENABLE_ADMIN=true
- ME_CONFIG_MONGODB_AUTH_DATABASE=admin
- ME_CONFIG_MONGODB_ADMINUSERNAME=singlestone
- ME_CONFIG_MONGODB_ADMINPASSWORD=singlestone
- ME_CONFIG_BASICAUTH_USERNAME=singlestone
- ME_CONFIG_BASICAUTH_PASSWORD=singlestone
depends_on:
- mongo