-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
50 lines (46 loc) · 1.06 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
version: '3.7'
services:
websocket-client:
build:
context: ./client
dockerfile: Dockerfile.dev
container_name: websocket-client
ports:
- 8080:8080
volumes:
- './client:/usr/app'
- '/usr/app/node_modules'
networks:
- websocket-example-network
websocket-server:
build:
context: ./server
dockerfile: Dockerfile.dev
container_name: websocket-server
command: "sh -c 'yarn install && yarn run dev'"
ports:
- 4000:4000
volumes:
- './server:/usr/app'
- '/usr/app/node_modules'
networks:
- websocket-example-network
depends_on:
- mongo
mongo:
# platform: linux/x86_64
image: mongo
container_name: mongo
environment:
- MONGO_INITDB_DATABASE=chat
- MONGO_INITDB_ROOT_USERNAME=bW9uZ28tdXNlcg==
- MONGO_INITDB_ROOT_PASSWORD=bW9uZ28tcGFzc3dk
ports:
- "27017:27017"
volumes:
- ./mongo-volume:/data/db
networks:
- websocket-example-network
networks:
websocket-example-network:
driver: bridge