-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
77 lines (72 loc) · 1.93 KB
/
docker-compose.yml
File metadata and controls
77 lines (72 loc) · 1.93 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
version: '3.8'
services:
postgres:
image: postgres:15
container_name: todo_postgres
environment:
POSTGRES_DB: todo_db
POSTGRES_USER: user
POSTGRES_PASSWORD: password
TZ: 'UTC'
ports:
- "5433:5432"
healthcheck:
test: ["CMD-SHELL", "pg_isready -U user -d todo_db"]
interval: 10s
timeout: 5s
retries: 5
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:8.8.2
container_name: todo_elasticsearch
environment:
- discovery.type=single-node
- xpack.security.enabled=false
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
- TZ=UTC
ports:
- "9200:9200"
- "9300:9300"
volumes:
- elastic_data:/usr/share/elasticsearch/data
healthcheck:
test: ["CMD-SHELL", "curl -s -f http://localhost:9200/_cluster/health | grep -vq '\"status\":\"red\"'"]
interval: 10s
timeout: 10s
retries: 10
minio:
image: minio/minio:RELEASE.2025-06-13T11-33-47Z
container_name: todo_minio
command: server /data --console-address ":9001"
environment:
MINIO_ROOT_USER: minioadmin
MINIO_ROOT_PASSWORD: minioadmin
TZ: 'UTC'
ports:
- "9003:9000" # API
- "9002:9001" # Console
volumes:
- minio_data:/data
healthcheck:
test: ["CMD", "mc", "ready", "local"]
interval: 10s
timeout: 5s
retries: 5
mc: # MinIO Client для создания бакета
image: minio/mc
depends_on:
minio:
condition: service_healthy
entrypoint: >
/bin/sh -c "
echo 'Waiting for MinIO to be fully ready...';
sleep 5;
/usr/bin/mc alias set myminio http://minio:9000 minioadmin minioadmin;
/usr/bin/mc mb myminio/attachments --ignore-existing;
/usr/bin/mc policy set public myminio/attachments;
echo 'MinIO bucket setup complete.';
exit 0;
"
volumes:
postgres_data:
elastic_data:
minio_data: