-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
53 lines (48 loc) · 1.13 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
53
version: '3'
volumes:
postgres_data_local: {}
django_static: {}
services:
django:
container_name: pdk-django
build:
context: .
dockerfile: ./Dockerfile
depends_on:
- postgres
volumes:
- django_static:/app/historian/static
env_file:
- variables.env
command: sh -c "sleep 10 && service sendmail start && python manage.py migrate && python manage.py collectstatic --no-input && gunicorn historian.wsgi --bind 0.0.0.0:80"
postgres:
image: mdillon/postgis:9.6
container_name: pdk-postgres
volumes:
- postgres_data_local:/var/lib/postgresql/data
env_file:
- variables.env
ports:
- "5432:5432"
nginx_ssl:
image: rsdnlesc/docker-term-letsencrypt
volumes:
- ./cert:/cert
- ./letsencrypt:/etc/letsencrypt
env_file:
- variables.env
restart: unless-stopped
depends_on:
- nginx
ports:
- 443:443
- 80:80
nginx:
image: nginx:1.15.8-alpine
container_name: nginx
volumes:
- ./nginx.conf:/etc/nginx/conf.d/default.conf
- django_static:/static
command: nginx -g 'daemon off;'
depends_on:
- django