forked from CDCRC-IITRPR/cdcrc_website
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
42 lines (36 loc) · 953 Bytes
/
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
version: '3'
services:
backend:
tty: true
stdin_open: true
build:
context: ./backend
dockerfile: Dockerfile
command: sh -c "python manage.py runserver 0.0.0.0:8000"
# Mapping Container PORT 8000 to Host PORT 8000
env_file:
- ./.env
volumes:
- './backend/src/:/backend/'
depends_on:
- postgres_db
nginx:
build:
context: ./nginx
dockerfile: Dockerfile
# Mapping Container PORT 80 to Host PORT 8000
ports:
- 8000:80
depends_on:
- backend
volumes:
- './backend/src/static/:/static/'
- './backend/src/media/:/media/'
postgres_db:
image: postgres:12.0-alpine
volumes:
- postgres_data:/var/lib/postgresql/data/
env_file:
- ./.env
volumes:
postgres_data: