-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathdocker-compose.yml
47 lines (44 loc) · 1.04 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
version: "3"
services:
postgres:
image: postgres:9.6
environment:
POSTGRES_USER: omahelsinki
POSTGRES_PASSWORD: omahelsinki
POSTGRES_DB: omahelsinki
ports:
- "5432:5432"
volumes:
- omahelsinki-postgres-data-volume:/var/lib/postgres/data
container_name: omahelsinki-db
django:
build:
context: ./
dockerfile: ./docker/django/Dockerfile
environment:
DATABASE_URL: postgres://omahelsinki:omahelsinki@omahelsinki-db/omahelsinki
volumes:
- .:/code
- omahelsinki-media-volume:/var/media/
- /code/node_modules
ports:
- "8000:8000"
depends_on:
- postgres
container_name: omahelsinki
react:
build:
context: ./
dockerfile: ./docker/react/Dockerfile
environment:
SERVER_URL: 0.0.0.0
container_name: omahelsinki-react
volumes:
- .:/code
- /code/node_modules
ports:
- "3000:3000"
command: ash -c "yarn && yarn start"
volumes:
? omahelsinki-postgres-data-volume
? omahelsinki-media-volume