-
Notifications
You must be signed in to change notification settings - Fork 2
/
docker-compose.yml
54 lines (49 loc) · 1.28 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
version: '3.8'
services:
tennis-server:
build:
context: ./server
command: python manage.py runserver 0.0.0.0:8000
container_name: tennis-server
depends_on:
- tennis-database
environment:
- PGDATABASE=tennis
- PGUSER=tennis
- PGPASSWORD=tennis
- PGHOST=tennis-database
ports:
- 8003:8000
volumes:
- ./server:/usr/src/app
tennis-database:
container_name: tennis-database
image: postgres:14-alpine
environment:
- POSTGRES_USER=tennis
- POSTGRES_PASSWORD=tennis
expose:
- 5432
volumes:
- tennis-database:/var/lib/postgresql/data
taxi-client:
build:
context: ./client
command: yarn start
container_name: tennis-client
depends_on:
- tennis-server
environment:
- CHOKIDAR_USEPOLLING=TRUE
# - REACT_APP_BASE_URL=http://192.168.0.156:8003
- REACT_APP_BASE_URL=http://127.0.0.1:8003
- WDS_SOCKET_PORT=0
ports:
- 3001:3000
stdin_open: true
volumes:
- ./client:/usr/src/app
# Volumes let you store data outside of the container lifecycle. By adding the tennis-database volume,
# all of the data we write to PostgreSQL will persist as the Docker container is started and stopped.
volumes:
tennis-database: