-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.prod.yml
94 lines (90 loc) · 2.45 KB
/
docker-compose.prod.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
version: '3'
services:
django:
build:
context: .
dockerfile: ./prod/Dockerfile
args:
DJANGO_CONFIGURATION: DockerComposeProdConfiguration
DJANGO_DATABASE_URL: postgres://postgres:postgres@postgres:5432/django
DJANGO_MINIO_STORAGE_ENDPOINT: minio:9000
DJANGO_MINIO_STORAGE_ACCESS_KEY: minioAccessKey
DJANGO_MINIO_STORAGE_SECRET_KEY: minioSecretKey
DJANGO_STORAGE_BUCKET_NAME: django-storage
DJANGO_MINIO_STORAGE_MEDIA_URL: http://localhost:9000/django-storage
command: [
"gunicorn",
"--bind",
"0.0.0.0:8000",
"--workers",
"8",
"uvdat.wsgi"
]
tty: true
env_file: ./prod/.env.docker-compose
volumes:
- ${NZ_INGEST_ROOT:-./sample_data}:/ingest
depends_on:
- postgres
- rabbitmq
- minio
platform: linux/amd64
celery:
build:
context: .
dockerfile: ./prod/Dockerfile
args:
DJANGO_CONFIGURATION: DockerComposeProdConfiguration
DJANGO_DATABASE_URL: postgres://postgres:postgres@postgres:5432/django
DJANGO_MINIO_STORAGE_ENDPOINT: minio:9000
DJANGO_MINIO_STORAGE_ACCESS_KEY: minioAccessKey
DJANGO_MINIO_STORAGE_SECRET_KEY: minioSecretKey
DJANGO_STORAGE_BUCKET_NAME: django-storage
DJANGO_MINIO_STORAGE_MEDIA_URL: http://localhost:9000/django-storage
command:
[
"celery",
"--app",
"uvdat.celery",
"worker",
"--loglevel",
"INFO",
"--without-heartbeat"
]
# Docker Compose does not set the TTY width, which causes Celery errors
tty: false
env_file: ./prod/.env.docker-compose
volumes:
- ${NZ_INGEST_ROOT:-./sample_data}:/ingest
depends_on:
- postgres
- rabbitmq
- minio
platform: linux/amd64
gen-vector-basemap:
build:
context: ./docker/tilemaker
dockerfile: Dockerfile
restart: no
volumes:
- vector-workdir:/work
- ./client/public/vectortiles:/data
web:
build:
context: .
dockerfile: ./prod/client.Dockerfile
args:
VUE_APP_OAUTH_CLIENT_ID: devClientId
VUE_APP_API_ROOT: /api/v1
VUE_APP_OAUTH_API_ROOT: /oauth/
volumes:
- ${LOCAL_SSL_CERT_DIR:-/etc/ssl/certs}:/etc/ssl/certs
- ./client/public/vectortiles:/client/public/vectortiles
ports:
- 80:80
- 443:443
depends_on:
- minio
- django
volumes:
vector-workdir: