-
-
Notifications
You must be signed in to change notification settings - Fork 263
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
285 lines (270 loc) · 7.07 KB
/
docker-compose.yml
File metadata and controls
285 lines (270 loc) · 7.07 KB
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
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
# Use this file for development only
services:
mariadb:
image: mariadb:latest
restart: always
environment:
- MYSQL_ROOT_PASSWORD=iop
- MYSQL_DATABASE=phpmyfaq
- MYSQL_USER=phpmyfaq
- MYSQL_PASSWORD=phpmyfaq
- MYSQL_ROOT_HOST=%
ports:
- '3306:3306'
volumes:
- ./volumes/mariadb:/var/lib/mysql
postgres:
image: postgres:latest
restart: always
environment:
- POSTGRES_DB=phpmyfaq
- POSTGRES_USER=phpmyfaq
- POSTGRES_PASSWORD=phpmyfaq
ports:
- '5432:5432'
volumes:
- ./volumes/postgres:/var/lib/postgresql/data
redis:
image: redis:8-alpine
restart: always
command: redis-server --appendonly yes
healthcheck:
test: [ 'CMD', 'redis-cli', 'ping' ]
interval: 10s
timeout: 5s
retries: 5
start_period: 10s
ports:
- '6379:6379'
volumes:
- ./volumes/redis:/data
#sqlserver:
# image: mcr.microsoft.com/mssql/server:2022-latest
# ports:
# - 1433:1433
# environment:
# SA_PASSWORD: 'phpMyFAQ-4.0'
# ACCEPT_EULA: 'Y'
apache:
profiles: ['apache']
build:
context: .
dockerfile: .docker/apache/Dockerfile
restart: always
stdin_open: true
environment:
- PMF_DB_HOST=db
- PMF_DB_NAME=phpmyfaq
- PMF_DB_USER=phpmyfaq
- PMF_DB_PASS=phpmyfaq
- PMF_DISABLE_HTACCESS=""
- PMF_TIMEZONE="Europe/Berlin"
- PMF_ENABLE_UPLOADS="On"
- PMF_MEMORY_LIMIT="2048M" # only for development
- PHP_LOG_ERRORS="On"
- PHP_ERROR_REPORTING="E_ALL & E_DEPRECATED" # Production Value: E_ALL & ~E_DEPRECATED
- OPENSEARCH_BASE_URI=http://opensearch:9201
- ELASTICSEARCH_BASE_URI=http://elasticsearch:9200
- SEARCH_WAIT_TIMEOUT=30
links:
- mariadb:db
- postgres
- redis
- elasticsearch
- opensearch
ports:
- '8080:80'
- '443:443'
volumes:
- ./phpmyfaq:/var/www/html
depends_on:
pnpm:
condition: service_completed_successfully
redis:
condition: service_started
nginx:
image: nginx:latest
restart: always
depends_on:
- php-fpm
links:
- php-fpm
volumes:
- ./phpmyfaq:/var/www/html
- ./.docker/nginx/default.conf:/etc/nginx/conf.d/default.conf
- ./.docker/cert.pem:/etc/ssl/cert.pem
- ./.docker/cert-key.pem:/etc/ssl/cert-key.pem
ports:
- '80:80'
- '443:443'
php-fpm:
build: .docker/php-fpm
restart: always
stdin_open: true
environment:
- PMF_DB_HOST=db
- PMF_DB_NAME=phpmyfaq
- PMF_DB_USER=phpmyfaq
- PMF_DB_PASS=phpmyfaq
- PMF_DISABLE_HTACCESS=""
- PMF_TIMEZONE="Europe/Berlin"
- PMF_ENABLE_UPLOADS="On"
- PMF_MEMORY_LIMIT="2048M" # only for development
- PHP_LOG_ERRORS="On"
- PHP_ERROR_REPORTING="E_ALL & E_DEPRECATED" # Production Value: E_ALL & ~E_DEPRECATED
- PHP_POST_MAX_SIZE="200M" # Increased upload limit
- PHP_UPLOAD_MAX_FILESIZE="200M" # Increased upload limit
- OPENSEARCH_BASE_URI=http://opensearch:9201
- ELASTICSEARCH_BASE_URI=http://elasticsearch:9200
- SEARCH_WAIT_TIMEOUT=30
links:
- mariadb:db
- postgres
- redis
- elasticsearch
- opensearch
volumes:
- ./phpmyfaq:/var/www/html
depends_on:
pnpm:
condition: service_completed_successfully
redis:
condition: service_started
frankenphp:
profiles: ['frankenphp']
build: .docker/frankenphp
restart: always
stdin_open: true
environment:
- PMF_DB_HOST=db
- PMF_DB_NAME=phpmyfaq
- PMF_DB_USER=phpmyfaq
- PMF_DB_PASS=phpmyfaq
- PMF_DISABLE_HTACCESS=""
- PMF_TIMEZONE="Europe/Berlin"
- PMF_ENABLE_UPLOADS="On"
- PMF_MEMORY_LIMIT="2048M" # only for development
- PHP_LOG_ERRORS="On"
- PHP_ERROR_REPORTING="E_ALL & E_DEPRECATED" # Production Value: E_ALL & ~E_DEPRECATED
- OPENSEARCH_BASE_URI=http://opensearch:9201
- ELASTICSEARCH_BASE_URI=http://elasticsearch:9200
- SEARCH_WAIT_TIMEOUT=30
links:
- mariadb:db
- postgres
- redis
- elasticsearch
- opensearch
ports:
- '80:80'
- '443:443'
- '443:443/udp' # HTTP/3
volumes:
- ./phpmyfaq:/var/www/html
- ./.docker/cert.pem:/etc/ssl/cert.pem
- ./.docker/cert-key.pem:/etc/ssl/cert-key.pem
- ./volumes/caddy_data:/data
- ./volumes/caddy_config:/config
depends_on:
pnpm:
condition: service_completed_successfully
redis:
condition: service_started
pnpm:
image: node:24-alpine
restart: 'no'
command: sh -c "corepack enable && corepack prepare pnpm@latest --activate && pnpm install && pnpm build"
working_dir: /app
stdin_open: true
tty: true
volumes:
- .:/app
depends_on:
- composer
composer:
image: composer:latest
restart: 'no'
command: composer install --verbose --ignore-platform-reqs
stdin_open: true
tty: true
volumes:
- .:/app
phpmyadmin:
image: phpmyadmin/phpmyadmin
restart: always
stdin_open: true
environment:
PMA_HOST: db
UPLOAD_LIMIT: 100M
links:
- mariadb:db
ports:
- '8000:80'
volumes:
- ./volumes/sessions:/sessions
depends_on:
- mariadb
pgadmin:
image: dpage/pgadmin4
restart: always
environment:
PGADMIN_DEFAULT_EMAIL: postgres@phpmyfaq.de
PGADMIN_DEFAULT_PASSWORD: postgres
PGADMIN_CONFIG_SERVER_MODE: 'False'
volumes:
- ./volumes/pgadmin:/root/.pgadmin
ports:
- '8008:80'
elasticsearch:
image: elasticsearch:8.16.5
container_name: phpmyfaq-42_elasticsearch-v8
restart: always
environment:
- cluster.name=phpmyfaq-cluster
- discovery.type=single-node
- bootstrap.memory_lock=true
- xpack.security.enabled=false
- "_JAVA_OPTIONS=-XX:UseSVE=0"
- "ES_JAVA_OPTS=-Xint"
ulimits:
memlock:
soft: -1
hard: -1
nofile:
soft: 65536
hard: 65536
user: elasticsearch
command:
[
'sh',
'-c',
'./bin/elasticsearch-plugin list | grep -q analysis-icu || ./bin/elasticsearch-plugin install analysis-icu && ./bin/elasticsearch',
]
volumes:
- ./volumes/esdata:/usr/share/elasticsearch/data
ports:
- '9200:9200'
- '9300:9300'
opensearch:
image: opensearchproject/opensearch:2.19.2
container_name: phpmyfaq-42_opensearch
environment:
- cluster.name=phpmyfaq-cluster
- node.name=phpmyfaq
- discovery.type=single-node
- bootstrap.memory_lock=true
- http.port=9201
- "_JAVA_OPTIONS=-XX:UseSVE=0"
- "OPENSEARCH_JAVA_OPTS=-Xms512m -Xmx512m"
- "DISABLE_INSTALL_DEMO_CONFIG=true"
- "DISABLE_SECURITY_PLUGIN=true"
- "DISABLE_PERFORMANCE_ANALYZER_AGENT=true"
ulimits:
memlock:
soft: -1
hard: -1
volumes:
- ./volumes/opensearchdata:/usr/share/opensearch/data
ports:
- '9201:9201'
- '9600:9600'