-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
47 lines (43 loc) · 898 Bytes
/
docker-compose.yml
File metadata and controls
47 lines (43 loc) · 898 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
version: '3.8'
services:
mongodb:
image: mongo:6-jammy
ports:
- '${DB_PORT}:27017'
networks:
- shared-network
volumes:
- db-data:/data/db
server:
build:
context: server
dockerfile: Dockerfile
environment:
- SERVER_PORT=${SERVER_PORT}
- DB_URL=${DB_URL}
ports:
- '${SERVER_PORT}:${SERVER_PORT}'
depends_on:
- mongodb
command: sh -c './bin/wait-for.sh mongodb:27017 -- npm run start'
networks:
- shared-network
restart: unless-stopped
client:
build:
context: client
dockerfile: Dockerfile
environment:
- CLIENT_PORT=${CLIENT_PORT}
- SERVER_URL=${SERVER_URL}
ports:
- '${CLIENT_PORT}:${CLIENT_PORT}'
depends_on:
- mongodb
networks:
- shared-network
restart: unless-stopped
networks:
shared-network:
volumes:
db-data: