-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
117 lines (112 loc) · 3.38 KB
/
docker-compose.yml
File metadata and controls
117 lines (112 loc) · 3.38 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
services:
dynamodb:
image: amazon/dynamodb-local:latest
user: root
ports:
- "8000:8000"
command: "-jar DynamoDBLocal.jar -sharedDb -dbPath /data"
volumes:
- dynamodb-data:/data
healthcheck:
test: ["CMD-SHELL", "timeout 2 bash -c '</dev/tcp/localhost/8000' 2>/dev/null"]
interval: 5s
timeout: 3s
retries: 5
start_period: 5s
redis:
image: redis:7-alpine
ports:
- "6379:6379"
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 5s
timeout: 3s
retries: 5
minio:
image: minio/minio
ports:
- "9000:9000"
- "9001:9001"
environment:
MINIO_ROOT_USER: minioadmin
MINIO_ROOT_PASSWORD: minioadmin
# Allow browser uploads via presigned URLs from any origin in dev
MINIO_API_CORS_ALLOW_ORIGIN: "*"
command: server /data --console-address ":9001"
volumes:
- minio-data:/data
healthcheck:
test: ["CMD", "mc", "ready", "local"]
interval: 5s
timeout: 3s
retries: 5
start_period: 10s
opensearch:
image: opensearchproject/opensearch:3.6.0
environment:
discovery.type: single-node
# Dev: security plugin off so the API is plain HTTP on :9200.
# Production should re-enable it via a sidecar config / TLS
# bundle and switch the URL scheme to https.
DISABLE_SECURITY_PLUGIN: "true"
DISABLE_INSTALL_DEMO_CONFIG: "true"
DISABLE_PERFORMANCE_ANALYZER_AGENT_CLI: "true"
# Quiet down the default INFO-level chatter — the dev console
# was getting buried under cluster-state, GC, and shard
# bookkeeping logs from a single-node setup that nobody is
# operating. WARN keeps real problems visible.
logger.level: WARN
OPENSEARCH_JAVA_OPTS: "-Xms512m -Xmx512m"
ports:
- "9200:9200"
volumes:
- opensearch-data:/usr/share/opensearch/data
healthcheck:
test: ["CMD-SHELL", "curl -s http://localhost:9200/_cluster/health | grep -E '\"status\":\"(green|yellow)\"'"]
interval: 10s
timeout: 5s
retries: 10
start_period: 30s
app:
build:
context: .
args:
# VERSION must be a unique-per-deploy identifier (git sha or
# release tag) so the upgrade banner fires on tabs left open
# across rebuilds. The Makefile sets this from `git rev-parse
# --short HEAD` before `docker compose up`; CI should set it
# explicitly. Defaults to "dev" — banner stays silent.
VERSION: ${VERSION:-dev}
ports:
- "8080:8080"
restart: on-failure
env_file: .env
environment:
PORT: "8080"
ENV: development
DYNAMODB_ENDPOINT: http://dynamodb:8000
DYNAMODB_TABLE: exdb
AWS_REGION: us-east-1
AWS_ACCESS_KEY_ID: local
AWS_SECRET_ACCESS_KEY: local
REDIS_URL: redis://redis:6379
JWT_SECRET: dev-secret-change-me
BASE_URL: http://localhost:8080
S3_ENDPOINT: http://minio:9000
S3_PUBLIC_ENDPOINT: http://localhost:9000
S3_BUCKET: ex-avatars
S3_ACCESS_KEY: minioadmin
S3_SECRET_KEY: minioadmin
S3_REGION: us-east-1
OPENSEARCH_URL: http://opensearch:9200
depends_on:
dynamodb:
condition: service_healthy
redis:
condition: service_healthy
opensearch:
condition: service_healthy
volumes:
dynamodb-data:
minio-data:
opensearch-data: