-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
48 lines (44 loc) · 1.02 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
version: '3.7'
services:
db:
image: postgres:14.2-alpine
ports:
- 55432:5432
environment:
- POSTGRES_USER=postgres
- POSTGRES_DB=postgres
- POSTGRES_PASSWORD=postgres
pustaka-bakend:
image: pustaka_backend:latest
build:
context: pustaka-backend
dockerfile: Dockerfile.app
container_name: pustaka-backend
volumes:
- ./pustaka-backend:/pustaka-backend
depends_on:
- db
environment:
- DEBUG=true
- DB_USER=postgres
- DB_PASSWORD=postgres
- DB_HOST=db
- DB_PORT=5432
command: sh -c "python manage.py makemigrations && python manage.py migrate && python manage.py runserver 0.0.0.0:8000"
ports:
- "8000:8000"
pustaka-frontend:
image: pustaka-frontend:latest
build:
context: pustaka-frontend
dockerfile: Dockerfile.app
nginx:
build: ./nginx
volumes:
- .:/nginx/etc/nginx/conf.d/
ports:
- "80:80"
volumes:
db-data:
pustaka_static_volume:
pustaka_media_volume: