forked from opengisch/QFieldCloud
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.override.prod.yml
54 lines (51 loc) · 1.49 KB
/
docker-compose.override.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
services:
nginx:
volumes:
- static_volume:/var/www/html/staticfiles/
- media_volume:/var/www/html/mediafiles/
minio:
image: minio/minio:RELEASE.2023-04-07T05-28-58Z
restart: unless-stopped
volumes:
- minio_data1:/data1
- minio_data2:/data2
- minio_data3:/data3
- minio_data4:/data4
environment:
MINIO_ROOT_USER: ${STORAGE_ACCESS_KEY_ID}
MINIO_ROOT_PASSWORD: ${STORAGE_SECRET_ACCESS_KEY}
MINIO_BROWSER_REDIRECT_URL: http://${QFIELDCLOUD_HOST}:${MINIO_BROWSER_PORT}
command: server /data{1...4} --console-address :9001
healthcheck:
test: [
"CMD",
"curl",
"-A",
"Mozilla/5.0 (X11; Linux x86_64; rv:30.0) Gecko/20100101 Firefox/30.0",
"-f",
"${STORAGE_ENDPOINT_URL}/minio/index.html"
]
interval: 5s
timeout: 20s
retries: 5
ports:
- ${MINIO_BROWSER_PORT}:9001
- ${MINIO_API_PORT}:9000
createbuckets:
image: minio/mc
depends_on:
minio:
condition: service_healthy
entrypoint: >
/bin/sh -c "
/usr/bin/mc config host add myminio ${STORAGE_ENDPOINT_URL} ${STORAGE_ACCESS_KEY_ID} ${STORAGE_SECRET_ACCESS_KEY};
/usr/bin/mc mb myminio/${STORAGE_BUCKET_NAME};
/usr/bin/mc policy set download myminio/${STORAGE_BUCKET_NAME}/users;
/usr/bin/mc version enable myminio/${STORAGE_BUCKET_NAME};
exit 0;
"
volumes:
minio_data1:
minio_data2:
minio_data3:
minio_data4: