-
Notifications
You must be signed in to change notification settings - Fork 13
/
docker-compose.yml
99 lines (94 loc) · 2.56 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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
version: "3"
services:
postgres:
image: postgres:10.5-alpine
container_name: postgres
restart: always
volumes:
- /pawprintsdata/postgres-data:/var/lib/postgresql/data
environment:
POSTGRES_PASSWORD: ${DB_PASSWORD}
POSTGRES_USER: ${DB_USER}
POSTGRES_DB: ${DB_NAME}
redis:
image: redis:alpine
restart: always
volumes:
- /pawprintsdata/redis-data:/data
expose:
- "6379"
worker:
build: .
command: python manage.py runworker websocket
volumes:
- .:/PawPrints
environment:
SECRET_KEY: ${SECRET_KEY}
SERVER_ENV: ${SERVER_ENV}
DB_NAME: ${DB_NAME}
DB_USER: ${DB_USER}
DB_PASSWORD: ${DB_PASSWORD}
DB_HOST: ${DB_HOST}
DB_PORT: ${DB_PORT}
EMAIL_HOST: ${EMAIL_HOST}
EMAIL_HOST_USER: ${EMAIL_HOST_USER}
EMAIL_HOST_PASSWORD: ${EMAIL_HOST_PASSWORD}
EMAIL_PORT: ${EMAIL_PORT}
EMAIL_USE_TLS: ${EMAIL_USE_TLS}
EMAIL_EMAIL_ADDR: ${EMAIL_EMAIL_ADDR}
RAVEN_DSN: ${RAVEN_DSN}
REDIS_URL: ${REDIS_URL}
links:
- redis
- postgres
huey_worker:
build: .
command: python manage.py run_huey
environment:
SECRET_KEY: ${SECRET_KEY}
SERVER_ENV: ${SERVER_ENV}
DB_NAME: ${DB_NAME}
DB_USER: ${DB_USER}
DB_PASSWORD: ${DB_PASSWORD}
DB_HOST: ${DB_HOST}
DB_PORT: ${DB_PORT}
EMAIL_HOST: ${EMAIL_HOST}
EMAIL_HOST_USER: ${EMAIL_HOST_USER}
EMAIL_HOST_PASSWORD: ${EMAIL_HOST_PASSWORD}
EMAIL_PORT: ${EMAIL_PORT}
EMAIL_USE_TLS: ${EMAIL_USE_TLS}
EMAIL_EMAIL_ADDR: ${EMAIL_EMAIL_ADDR}
RAVEN_DSN: ${RAVEN_DSN}
REDIS_URL: ${REDIS_URL}
volumes:
- .:/PawPrints
links:
- redis
- postgres
web:
build: .
command: sh -c "python manage.py renderfiles && python manage.py compress && python manage.py migrate && daphne -b 0.0.0.0 -p 8000 pawprints.asgi:application"
environment:
SECRET_KEY: ${SECRET_KEY}
SERVER_ENV: ${SERVER_ENV}
DB_NAME: ${DB_NAME}
DB_USER: ${DB_USER}
DB_PASSWORD: ${DB_PASSWORD}
DB_HOST: ${DB_HOST}
DB_PORT: ${DB_PORT}
EMAIL_HOST: ${EMAIL_HOST}
EMAIL_HOST_USER: ${EMAIL_HOST_USER}
EMAIL_HOST_PASSWORD: ${EMAIL_HOST_PASSWORD}
EMAIL_PORT: ${EMAIL_PORT}
EMAIL_USE_TLS: ${EMAIL_USE_TLS}
EMAIL_EMAIL_ADDR: ${EMAIL_EMAIL_ADDR}
RAVEN_DSN: ${RAVEN_DSN}
REDIS_URL: ${REDIS_URL}
GOOGLE_ID: ${GOOGLE_ANALYTICS}
volumes:
- .:/PawPrints
ports:
- "8000:8000"
depends_on:
- redis
- postgres