-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
61 lines (58 loc) · 1.33 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
51
52
53
54
55
56
57
58
59
60
61
version: '3'
services:
tetris-client-dev:
image: node:10
container_name: tetris-client-dev
volumes:
- ./client:/home/node/public/
environment:
- REACT_APP_TETRIS_APP_PORT=3005
- REACT_APP_DOMAIN=0.0.0.0
- REACT_APP_TETRIS_API_PORT=3006
- REACT_APP_NODE_ENV=devlopment
working_dir: /home/node/public
command: "bash -c 'npm install; npm run build; npm run start'"
ports:
- 3005:3005
restart: unless-stopped
db:
image: postgres:latest
container_name: db
environment:
POSTGRES_USER: user42
POSTGRES_PASSWORD: example
volumes:
- ./server/db:/docker-entrypoint-initdb.d/
ports:
- 5432:5432
restart: always
db_admin:
image: adminer
container_name: db_admin
restart: always
depends_on:
- db
ports:
- 3004:8080
links:
- db
tetris-api-dev:
image: node:10
container_name: tetris-api-dev
volumes:
- ./server:/home/node/app/api
environment:
- MAIN_PORT=3006
- DOMAIN=0.0.0.0
- PG_HOST=db
- POSTGRES_USER=user42
- POSTGRES_PASSWORD=example
- POSTGRES_PORT=5432
working_dir: /home/node/app/api
command: "bash -c 'npm install; npm run server:dev'"
ports:
- 3006:3006
restart: always
depends_on:
- db_admin
- db