-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
78 lines (73 loc) · 1.82 KB
/
docker-compose.yml
File metadata and controls
78 lines (73 loc) · 1.82 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
version: "3.9"
services:
mysql:
image: mysql:8.4
container_name: sms_gateway_mysql
restart: unless-stopped
environment:
MYSQL_DATABASE: sms_gateway
MYSQL_USER: sms_user
MYSQL_PASSWORD: sms_pass
MYSQL_ROOT_PASSWORD: root_pass
ports:
- "3306:3306"
volumes:
- mysql_data:/var/lib/mysql
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-h", "localhost"]
interval: 10s
timeout: 5s
retries: 5
rabbitmq:
image: rabbitmq:3.13-management
container_name: sms_gateway_rabbitmq
restart: unless-stopped
environment:
RABBITMQ_DEFAULT_USER: rabbit_user
RABBITMQ_DEFAULT_PASS: rabbit_pass
ports:
- "5672:5672"
- "15672:15672"
volumes:
- rabbitmq_data:/var/lib/rabbitmq
healthcheck:
test: ["CMD", "rabbitmq-diagnostics", "ping"]
interval: 10s
timeout: 5s
retries: 5
app:
build: .
image: sms-gateway:latest
container_name: sms_gateway_app
depends_on:
mysql:
condition: service_healthy
rabbitmq:
condition: service_healthy
environment:
LISTEN_ADDR: ":8080"
DB_USER_NAME: sms_user
DB_PASSWORD: sms_pass
DB_HOST: mysql
DB_PORT: 3306
DB_NAME: sms_gateway
RABBIT_URI: amqp://rabbit_user:rabbit_pass@rabbitmq:5672/
RABBIT_SMS_EXCHANGE: sms_exchange
EXPRESS_QUEUE: sms_express
NORMAL_QUEUE: sms_normal
OTEL_EXPORTER_OTLP_ENDPOINT: localhost:4317
OTEL_EXPORTER_OTLP_INSECURE: true
ports:
- "8080:8080"
jaeger:
image: jaegertracing/all-in-one:1.57
container_name: jaeger
ports:
- "16686:16686" # UI
- "4317:4317" # OTLP gRPC
- "4318:4318" # OTLP HTTP
environment:
- COLLECTOR_OTLP_ENABLED=true
volumes:
mysql_data:
rabbitmq_data: