-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
executable file
·39 lines (38 loc) · 1.05 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
version: '3'
services:
web:
user: $uid:$gid
build:
context: .
ports:
- "${WEB_PORT}:8000"
volumes:
- .:/code
command: >
sh -c "python manage.py wait_for_db &&
python manage.py migrate &&
python manage.py runserver 0.0.0.0:8000"
environment:
- DB_HOST=db
- DB_NAME=${POSTGRES_DB}
- DB_USER=${POSTGRES_USER}
- DB_PASS=${POSTGRES_PASSWORD}
- SECRET_KEY=${SECRET_KEY}
- EMAIL_HOST=${EMAIL_HOST}
- EMAIL_HOST_USER=${EMAIL_HOST_USER}
- EMAIL_HOST_PASSWORD=${EMAIL_HOST_PASSWORD}
- EMAIL_POST=${EMAIL_PORT}
- EMAIL_USE_TLS=${EMAIL_USE_TLS}
- ENVIRONMENT=${ENVIRONMENT}
- TWO_FACTOR_TOKEN_LEN=${TWO_FACTOR_TOKEN_LEN}
- TWO_FACTOR_TOKEN_VALID_MINUTES=${TWO_FACTOR_TOKEN_VALID_MINUTES}
depends_on:
- db
db:
image: postgres:10-alpine
ports:
- "${DB_PORT}:5432"
environment:
- POSTGRES_DB=${POSTGRES_DB}
- POSTGRES_USER=${POSTGRES_USER}
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}