-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathdocker-compose.yml
48 lines (47 loc) · 1.08 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
version: '3.5'
services:
backend:
build:
dockerfile: Dockerfile
network: host
context: backend
ports:
- 9999:8080
env_file:
- backend/.env
profiles:
- "dev"
frontend:
build:
dockerfile: Dockerfile
network: host
context: frontend
volumes:
- ./frontend/static/config.dev.json:/app/build/client/config.json:ro
ports:
- 9998:3000
profiles:
- "dev"
- "frontend"
mongo:
image: mongo
restart: always
command: mongod --replSet rs0 --bind_ip_all
ports:
- 27017:27017 # admin
environment:
MONGO_INITDB_DATABASE: astralys
healthcheck:
test: |
test $$(mongosh --quiet --eval "try { rs.initiate({ _id: 'rs0', members: [{ _id: 0, host: '127.0.0.1' }] }).ok } catch (_) { rs.status().ok }") -eq 1
interval: 3s
start_period: 3s
volumes:
- ./data:/out
mongo-express:
image: mongo-express
restart: always
network_mode: host
environment:
ME_CONFIG_MONGODB_SERVER: 127.0.0.1
ME_CONFIG_MONGODB_PORT: 27017