-
Notifications
You must be signed in to change notification settings - Fork 18
/
docker-compose.local.yml
194 lines (172 loc) · 5.74 KB
/
docker-compose.local.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
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
---
x-variables: &variables
environment:
TIMEZONE: "UTC"
GK_IS_UNIT_TESTING: "true"
# GK_WEBSITE_HOST must me the stack internal way off accessing the website
GK_WEBSITE_HOST: nginx
# GK_WEBSITE_FQDN How the webiste is reached externally
GK_WEBSITE_FQDN: "${GK_FQDN:-localhost}"
# GK_WEBSITE_PORT How the webiste is reached externally
GK_WEBSITE_PORT: "3${GK_INSTANCE_ID:-10}1"
GK_SITE_BASE_SERVER_FQDN: "${GK_FQDN:-localhost}:3${GK_INSTANCE_ID:-10}1"
GK_SITE_BASE_SERVER_URL: "http://${GK_FQDN:-localhost}:3${GK_INSTANCE_ID:-10}1"
GK_CDN_SERVER_URL: "http://${GK_FQDN:-localhost}:3${GK_INSTANCE_ID:-10}2"
GK_SENTRY_DSN: "${SENTRY_DSN:-}"
GK_SENTRY_ENV: "${SENTRY_ENV:-}"
GK_MINIO_SERVER_URL_EXTERNAL: "http://${GK_FQDN:-localhost}:3${GK_INSTANCE_ID:-10}3"
MINIO_ACCESS_KEY: "access_key"
MINIO_SECRET_KEY: "secret_key"
GK_MINIO_PICTURES_PROCESSOR_MINIO_ACCESS_KEY: "pp_access_key"
GK_MINIO_PICTURES_PROCESSOR_MINIO_SECRET_KEY: "pp_secret_key"
GK_MINIO_WEBHOOK_AUTH_TOKEN_PICTURE_UPLOADED: "token1"
GK_MINIO_WEBHOOK_AUTH_TOKEN_PP_DOWNLOADER: "token2"
GK_MINIO_WEBHOOK_AUTH_TOKEN_PP_UPLOADER: "token3"
GK_AUTH_TOKEN_DROP_S3_FILE_UPLOAD_REQUEST: "token4"
GK_DEBUG: "True"
GK_DEVEL: "True"
GK_ENVIRONMENT: "dev"
GK_INSTANCE_NAME: "dev"
GK_DEPLOY_DATE: "2020-08-07T17:23:35.869127Z"
GK_DB_DRIVER: "pgsql"
GK_DB_HOST: "postgres"
GK_DB_DSN: "pgsql:host=postgres;dbname=geokrety"
GK_DB_USER: "geokrety"
GK_DB_PASSWORD: "geokrety"
GK_DB_GPG_PASSWORD: "geokrety"
GK_DB_SECRET_KEY: "secretkey"
GK_SITE_EMAIL: "geokrety-dev@kumy.net"
GK_SITE_EMAIL_SUPPORT: "geokrety-qa+support@geokrety.org"
GK_SITE_EMAIL_REGISTRATION: "geokrety-qa+registration@geokrety.org"
GK_SITE_EMAIL_MESSAGE_CENTER: "geokrety-qa+message-center@geokrety.org"
GK_PASSWORD_HASH_ROTATION: "11"
GK_PASSWORD_HASH: "something"
GK_PASSWORD_SEED: "seed"
GK_SESSION_IN_REDIS: "true"
services:
adminer:
image: adminer
ports:
- 3${GK_INSTANCE_ID:-10}5:8080
environment:
ADMINER_DEFAULT_SERVER: postgres
nginx:
image: geokrety/nginx:main
<<: *variables
volumes:
- ./configs/nginx/templates/default-no-req-limit.conf.template:/etc/nginx/templates/default.conf.template:ro
- ./website/public:/var/www/html:ro
- shared-assets-volume:/var/www/html/assets/compressed:ro
ports:
- "3${GK_INSTANCE_ID:-10}1:3${GK_INSTANCE_ID:-10}1"
depends_on:
- website
healthcheck:
disable: true
website:
image: geokrety/website:devel
build:
context: ./
<<: *variables
volumes:
# ## You may wish to enable local mount on your local machine
# - .:/var/www/geokrety/
- shared-assets-volume:/var/www/geokrety/website/public/assets/compressed:rw
dns:
- 8.8.8.8
depends_on:
- postgres
- cdn
- minio
- redis
- svg-to-png
- pictures-downloader
- pictures-uploader
healthcheck:
disable: true
cdn:
image: geokrety/cdn:main
# build: https://github.com/geokrety/GeoKrety-Static.git#main
ports:
- "3${GK_INSTANCE_ID:-10}2:80"
postgres:
image: geokrety/postgres:main
# build: https://github.com/geokrety/geokrety-postgres.git
volumes:
- /etc/localtime:/etc/localtime:ro
- ./website/db/dumps/:/docker-entrypoint-initdb.d/
- ./website/db/srtm/:/srtm/
tmpfs:
- /var/lib/postgresql/data
ports:
- "5${GK_INSTANCE_ID:-10}6:5432"
environment:
TZ: GMT
POSTGRES_DB: "geokrety"
POSTGRES_USER: "geokrety"
POSTGRES_PASSWORD: "geokrety"
# POSTGIS_ENABLE_OUTDB_RASTERS: 1
POSTGIS_GDAL_ENABLED_DRIVERS: ENABLE_ALL
redis:
image: redis:5
minio:
image: minio/minio
command:
- "server"
- "/data"
- "--console-address"
- ":9001"
environment:
MINIO_ROOT_USER: access_key
MINIO_ROOT_PASSWORD: secret_key
CONSOLE_SECURE_TLS_REDIRECT: "off"
MINIO_BROWSER_REDIRECT_URL: "http://${GK_FQDN:-localhost}:3004"
# # tmpfs is not working anymore on Minio :(
# tmpfs:
# - /data
ports:
- "3${GK_INSTANCE_ID:-10}3:9000"
- "3${GK_INSTANCE_ID:-10}4:9001"
depends_on:
- pictures-uploader
# # used to build image only
# pictures-processor:
# image: geokrety/pictures-processor-base:main
# # build:
# # context: https://github.com/geokrety/geokrety-pictures-processor.git
# # dockerfile: Dockerfile.base
# command:
# - "/bin/true"
pictures-downloader:
image: geokrety/pictures-processor-downloader:main
# build:
# context: https://github.com/geokrety/geokrety-pictures-processor.git
# dockerfile: Dockerfile.downloader
# args:
# BASE_TAG: main
environment:
GK_WEBSITE_PORT: 3${GK_INSTANCE_ID:-10}1
GK_MINIO_PICTURES_PROCESSOR_MINIO_ACCESS_KEY: pp_access_key
GK_MINIO_PICTURES_PROCESSOR_MINIO_SECRET_KEY: pp_secret_key
GK_MINIO_WEBHOOK_AUTH_TOKEN_PP_DOWNLOADER: "token2"
GK_AUTH_TOKEN_DROP_S3_FILE_UPLOAD_REQUEST: "token4"
SENTRY_DSN: "${SENTRY_DSN:-}"
SENTRY_ENV: "${SENTRY_ENV:-}"
pictures-uploader:
image: geokrety/pictures-processor-uploader:main
# build:
# context: https://github.com/geokrety/geokrety-pictures-processor.git
# dockerfile: Dockerfile.uploader
# args:
# BASE_TAG: main
environment:
MINIO_ACCESS_KEY: access_key
MINIO_SECRET_KEY: secret_key
GK_MINIO_WEBHOOK_AUTH_TOKEN_PP_UPLOADER: token3
SENTRY_DSN: "${SENTRY_DSN:-}"
SENTRY_ENV: "${SENTRY_ENV:-}"
svg-to-png:
image: geokrety/svg-to-png:main
# build: https://github.com/geokrety/geokrety-svg-to-png.git
volumes:
shared-assets-volume: