-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
103 lines (97 loc) · 2.87 KB
/
docker-compose.yml
File metadata and controls
103 lines (97 loc) · 2.87 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
services:
# ============================================
# PostgreSQL 18 - Event Store + Relational DB
# ============================================
postgres:
image: postgres:18-alpine
container_name: rh-postgres
ports:
- "5432:5432"
environment:
POSTGRES_DB: rh_training
POSTGRES_USER: dev
POSTGRES_PASSWORD: dev123
# Configurações de performance
POSTGRES_INITDB_ARGS: "--encoding=UTF8 --locale=C"
volumes:
- postgres_data:/var/lib/postgresql/data
- ./docker/init-schemas.sql:/docker-entrypoint-initdb.d/01-init-schemas.sql
healthcheck:
test: ["CMD-SHELL", "pg_isready -U dev -d rh_training"]
interval: 5s
timeout: 5s
retries: 5
# ============================================
# Redis 7 - Cache L2
# ============================================
redis:
image: redis:7-alpine
container_name: rh-redis
ports:
- "6379:6379"
command: redis-server --appendonly yes
volumes:
- redis_data:/data
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 5s
timeout: 3s
retries: 5
# ============================================
# Azurite - Azure Storage Emulator
# ============================================
azurite:
image: mcr.microsoft.com/azure-storage/azurite
container_name: rh-azurite
ports:
- "10000:10000" # Blob
- "10001:10001" # Queue
- "10002:10002" # Table
volumes:
- azurite_data:/data
command: azurite --blobHost 0.0.0.0 --queueHost 0.0.0.0 --tableHost 0.0.0.0
# ============================================
# SQL Server - Backend do Service Bus Emulator
# ============================================
sqlserver:
image: mcr.microsoft.com/mssql/server:2022-latest
container_name: rh-sqlserver
ports:
- "1433:1433"
environment:
ACCEPT_EULA: "Y"
MSSQL_SA_PASSWORD: "ServiceBus123!"
MSSQL_PID: "Developer"
volumes:
- sqlserver_data:/var/opt/mssql
healthcheck:
test: ["CMD-SHELL", "/opt/mssql-tools18/bin/sqlcmd -C -S localhost -U sa -P ServiceBus123! -Q 'SELECT 1' > /dev/null"]
interval: 10s
timeout: 5s
retries: 5
start_period: 60s
# ============================================
# Azure Service Bus Emulator
# ============================================
servicebus:
image: mcr.microsoft.com/azure-messaging/servicebus-emulator:latest
container_name: rh-servicebus
ports:
- "5672:5672"
environment:
ACCEPT_EULA: "Y"
MSSQL_SA_PASSWORD: "ServiceBus123!"
SQL_SERVER: "sqlserver"
depends_on:
sqlserver:
condition: service_healthy
volumes:
- ./docker/servicebus-config.json:/ServiceBus_Emulator/ConfigFiles/Config.json
volumes:
postgres_data:
redis_data:
azurite_data:
sqlserver_data:
networks:
default:
name: rh-network