-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
50 lines (47 loc) · 1017 Bytes
/
docker-compose.yml
File metadata and controls
50 lines (47 loc) · 1017 Bytes
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
services:
app:
build:
context: .
dockerfile: Dockerfile
ports:
- "3000:3000"
environment:
- NODE_ENV=development
# - NODE_ENV=production
env_file:
- .env
volumes:
- ./src:/app/src
- ./logs:/app/logs
command: npm run start:dev
# command: npm run start:prod
depends_on:
- mongo
mongo:
image: mongo:latest
container_name: mongo-aptos-indexer
restart: unless-stopped
command: --port ${DB_PORT}
environment:
MONGO_INITDB_ROOT_USERNAME: ${DB_USER}
MONGO_INITDB_ROOT_PASSWORD: ${DB_PASS}
ports:
- '${DB_PORT}:${DB_PORT}'
volumes:
- mongodb_data:/data/db
healthcheck:
test:
[
'CMD',
'mongosh',
'--port',
'${DB_PORT}',
'--eval',
"db.adminCommand('ping')",
]
interval: 10s
timeout: 10s
retries: 5
start_period: 40s
volumes:
mongodb_data: