-
Notifications
You must be signed in to change notification settings - Fork 10
/
docker-compose.yml
52 lines (49 loc) · 1.19 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
services:
app:
build:
context: .
args:
- DEV=true
container_name: club-app
ports:
- '8000:8000'
volumes:
- ./app:/app
command: >
sh -c "python manage.py wait_for_db &&
python manage.py migrate &&
python manage.py init_superuser &&
python manage.py runserver 0.0.0.0:8000"
# env_file:
# - .env
environment:
- DJANGO_ENV=dev
- DB_HOST=osc-dev-db
- DB_NAME=devdatabase
- DB_USER=devuser
- DB_PASS=devpass
- DEBUG=1
- DJANGO_ALLOWED_HOSTS=*
- S3_STORAGE_BACKEND=0
- CREATE_SUPERUSER=1
- DJANGO_SUPERUSER_EMAIL=${DJANGO_SUPERUSER_EMAIL:-admin@example.com}
- DJANGO_SUPERUSER_PASS=${DJANGO_SUPERUSER_PASS:-changeme}
depends_on:
- postgres
postgres:
image: postgres:13-alpine
container_name: osc-dev-db
volumes:
- postgres-osc-dev:/var/lib/postgresql/data
environment:
- POSTGRES_DB=devdatabase
- POSTGRES_USER=devuser
- POSTGRES_PASSWORD=devpass
coverage:
image: nginx
ports:
- '8001:80'
volumes:
- ./app/htmlcov:/usr/share/nginx/html
volumes:
postgres-osc-dev: