-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.initial.yml
56 lines (52 loc) · 1.14 KB
/
docker-compose.initial.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
51
52
53
54
55
56
services:
node-backend:
image: node:16-alpine
# restart: unless-stopped
working_dir: /home/node/app
ports:
- 4000:4000
environment:
- NODE_ENV=development
- PORT=4000
- SESSION_SECRET=uiyHB^&*Cg^&*F#^doy8bxyzGFC^
- MONGO_URL=mongodb://mongo:27017
- DB_NAME=awt_project
- REDIS_URL=redis:6379
- CORS_ORIGIN=http://localhost:3000
volumes:
- ./backend:/home/node/app
command: npm i
depends_on:
- mongo
- redis
node-frontend:
image: node:16-alpine
# restart: unless-stopped
working_dir: /home/node/app
volumes:
- ./frontend:/home/node/app
command: npm i
ports:
- 3000:3000
environment:
- NODE_ENV=development
- PORT=3000
- REACT_APP_API_URL=http://localhost:4000/
- REACT_APP_SOCKET_PATH=/socket.io
depends_on:
- node-backend
mongo:
image: mongo:4
restart: unless-stopped
ports:
- 27018:27017
volumes:
- mongo-data:/data/db
redis:
image: redis:6-alpine
restart: unless-stopped
volumes:
- redis-data:/data
volumes:
mongo-data:
redis-data: