-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose-desarrollo.yml
50 lines (46 loc) · 1.18 KB
/
docker-compose-desarrollo.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
version: '3.8'
services:
bd:
container_name: colev-api-bd-desarrollo
image: mongo:5.0.9
networks:
- colev-api-desarrollo
volumes:
- ./basededatos:/data/db
ports:
- ${BD_PUERTO}:27017
healthcheck:
test: echo 'db.runCommand({serverStatus:1}).ok' | mongo admin -u ${BD_USUARIO} -p ${BD_CLAVE} --quiet | grep 1
interval: 10s
timeout: 10s
retries: 3
start_period: 20s
environment:
MONGO_INITDB_ROOT_USERNAME: ${BD_USUARIO}
MONGO_INITDB_ROOT_PASSWORD: ${BD_CLAVE}
MONGO_INITDB_DATABASE: covid
cache:
container_name: colev-api-cache-desarrollo
image: redis:7.0-alpine
networks:
- colev-api-desarrollo
ports:
- ${CACHE_PUERTO}:6379
mongo-express:
container_name: colev-api-mongoexpress
image: mongo-express
networks:
- colev-api-desarrollo
ports:
- 8081:8081
depends_on:
bd:
condition: service_healthy
cache:
condition: service_started
environment:
ME_CONFIG_MONGODB_ADMINUSERNAME: ${BD_USUARIO}
ME_CONFIG_MONGODB_ADMINPASSWORD: ${BD_CLAVE}
ME_CONFIG_MONGODB_SERVER: bd
networks:
colev-api-desarrollo: