-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.mcp-chat-admin.yml
More file actions
237 lines (229 loc) · 8.71 KB
/
docker-compose.mcp-chat-admin.yml
File metadata and controls
237 lines (229 loc) · 8.71 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
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
# Platform Engineering Copilot - Full Stack (MCP + Chat + Admin)
# Complete deployment: All services for full platform functionality
# Use this for complete platform with chat UI and admin management
#
# Usage: docker-compose -f docker-compose.mcp-chat-admin.yml up -d
#
# Ports:
# - 5100: MCP Server (AI agents)
# - 5001: Chat UI (end-user chat interface)
# - 5050: Admin API (REST API for template/environment management)
# - 5003: Admin Client (Blazor WASM web UI for platform admins)
networks:
platform-network:
driver: bridge
volumes:
sqlserver-data:
platform-logs:
services:
# SQL Server Database (Azure SQL Edge for ARM64/Apple Silicon compatibility)
sqlserver:
image: mcr.microsoft.com/azure-sql-edge:latest
platform: linux/arm64
container_name: pec-sqlserver
hostname: sqlserver
restart: unless-stopped
environment:
- ACCEPT_EULA=Y
- MSSQL_SA_PASSWORD=${SA_PASSWORD:-PlatformDB123!}
- MSSQL_PID=Developer
ports:
- "1433:1433"
volumes:
- sqlserver-data:/var/opt/mssql
networks:
- platform-network
healthcheck:
test: ["CMD-SHELL", "exit 0"]
interval: 10s
timeout: 5s
retries: 3
start_period: 30s
# MCP Server (Multi-Agent Orchestrator)
platform-mcp:
platform: linux/amd64
build:
context: .
dockerfile: src/Platform.Engineering.Copilot.Mcp/Dockerfile
target: final
image: platform-engineering-copilot-mcp:latest
container_name: pec-mcp
hostname: platform-mcp
restart: unless-stopped
depends_on:
sqlserver:
condition: service_healthy
environment:
- ASPNETCORE_ENVIRONMENT=${ASPNETCORE_ENVIRONMENT:-Production}
- ASPNETCORE_URLS=http://0.0.0.0:5100
# Database
- ConnectionStrings__DefaultConnection=Server=sqlserver,1433;Database=PlatformDb;User=sa;Password=${SA_PASSWORD:-PlatformDB123!};TrustServerCertificate=true;MultipleActiveResultSets=true;Encrypt=false
- DatabaseProvider=SqlServer
# Azure Configuration
- AZURE_TENANT_ID=${AZURE_TENANT_ID:-}
- AZURE_CLIENT_ID=${AZURE_CLIENT_ID:-}
- AZURE_CLIENT_SECRET=${AZURE_CLIENT_SECRET:-}
- AZURE_SUBSCRIPTION_ID=${AZURE_SUBSCRIPTION_ID:-}
- Gateway__Azure__SubscriptionId=${AZURE_SUBSCRIPTION_ID:-}
- Gateway__Azure__TenantId=${AZURE_TENANT_ID:-}
- Gateway__Azure__CloudEnvironment=${AZURE_CLOUD_ENVIRONMENT:-AzureGovernment}
- Gateway__Azure__UseManagedIdentity=${AZURE_USE_MANAGED_IDENTITY:-false}
- Gateway__Azure__Enabled=${AZURE_ENABLED:-true}
# Azure OpenAI Configuration
- Gateway__AzureOpenAI__ApiKey=${AZURE_OPENAI_API_KEY:-}
- Gateway__AzureOpenAI__Endpoint=${AZURE_OPENAI_ENDPOINT:-https://mcp-ai.openai.azure.us/}
- Gateway__AzureOpenAI__DeploymentName=${AZURE_OPENAI_DEPLOYMENT:-gpt-4o}
- Gateway__AzureOpenAI__ChatDeploymentName=${AZURE_OPENAI_CHAT_DEPLOYMENT:-gpt-4o}
- Gateway__AzureOpenAI__EmbeddingDeploymentName=${AZURE_OPENAI_EMBEDDING_DEPLOYMENT:-text-embedding-ada-002}
# GitHub Configuration
- Gateway__GitHub__AccessToken=${GITHUB_TOKEN:-}
- Gateway__GitHub__Enabled=${GITHUB_ENABLED:-true}
# Git Sync Configuration
- GitSync__GitHubToken=${GITHUB_TOKEN:-}
- GitSync__AzureDevOpsToken=${AZURE_DEVOPS_TOKEN:-}
- GitSync__DefaultSyncIntervalMinutes=${GIT_SYNC_INTERVAL:-15}
- GitSync__AutoSyncEnabled=${GIT_AUTO_SYNC_ENABLED:-true}
ports:
- "5100:5100"
volumes:
- platform-logs:/app/logs
- ./appsettings.json:/app/appsettings.json:ro
- ~/.azure:/root/.azure:ro
networks:
- platform-network
# Chat UI (Web Interface for End Users)
platform-chat:
platform: linux/amd64
build:
context: .
dockerfile: src/Platform.Engineering.Copilot.Chat/Dockerfile
target: runtime
image: platform-engineering-copilot-chat:latest
container_name: pec-chat
hostname: platform-chat
restart: unless-stopped
depends_on:
sqlserver:
condition: service_healthy
platform-mcp:
condition: service_started
environment:
- ASPNETCORE_ENVIRONMENT=${ASPNETCORE_ENVIRONMENT:-Production}
- ASPNETCORE_URLS=http://0.0.0.0:5001
- DatabaseProvider=SqlServer
- ConnectionStrings__DefaultConnection=Server=sqlserver,1433;Database=PlatformChatDb;User=sa;Password=${SA_PASSWORD:-PlatformDB123!};TrustServerCertificate=true;MultipleActiveResultSets=true;Encrypt=false
- ConnectionStrings__SqlServerConnection=Server=sqlserver,1433;Database=PlatformDb;User=sa;Password=${SA_PASSWORD:-PlatformDB123!};TrustServerCertificate=true;MultipleActiveResultSets=true;Encrypt=false
- McpServer__BaseUrl=http://platform-mcp:5100
- Logging__LogLevel__Default=Information
ports:
- "5001:5001"
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:5001/health"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
volumes:
- platform-logs:/app/logs
networks:
- platform-network
# Admin API (Template & Environment Management)
platform-admin-api:
platform: linux/amd64
build:
context: .
dockerfile: src/Platform.Engineering.Copilot.Admin.API/Dockerfile
target: final
image: platform-engineering-copilot-admin-api:latest
container_name: pec-admin-api
hostname: platform-admin-api
restart: unless-stopped
depends_on:
sqlserver:
condition: service_healthy
platform-mcp:
condition: service_started
environment:
- ASPNETCORE_ENVIRONMENT=Development
- ASPNETCORE_URLS=http://0.0.0.0:5050
- ASPNETCORE_HTTP_PORTS=5050
# Database
- ConnectionStrings__DefaultConnection=Server=sqlserver,1433;Database=PlatformDb;User=sa;Password=${SA_PASSWORD:-PlatformDB123!};TrustServerCertificate=true;MultipleActiveResultSets=true;Encrypt=false
- DatabaseProvider=SqlServer
# CORS - Allow Admin Client
- Cors__AllowedOrigins=http://localhost:5003,http://platform-admin-client:80,http://localhost:5000,http://localhost:5002
# Azure Configuration for Deployments
- AZURE_TENANT_ID=${AZURE_TENANT_ID:-}
- AZURE_CLIENT_ID=${AZURE_CLIENT_ID:-}
- AZURE_CLIENT_SECRET=${AZURE_CLIENT_SECRET:-}
- AZURE_SUBSCRIPTION_ID=${AZURE_SUBSCRIPTION_ID:-}
- Gateway__Azure__SubscriptionId=${AZURE_SUBSCRIPTION_ID:-}
- Gateway__Azure__TenantId=${AZURE_TENANT_ID:-}
- Gateway__Azure__ClientId=${AZURE_CLIENT_ID:-}
- Gateway__Azure__ClientSecret=${AZURE_CLIENT_SECRET:-}
- Gateway__Azure__CloudEnvironment=${AZURE_CLOUD_ENVIRONMENT:-AzureGovernment}
- Gateway__Azure__UseManagedIdentity=${AZURE_USE_MANAGED_IDENTITY:-false}
- Gateway__Azure__Enabled=${AZURE_ENABLED:-true}
# Azure OpenAI (for NL template matching)
- Gateway__AzureOpenAI__ApiKey=${AZURE_OPENAI_API_KEY:-}
- Gateway__AzureOpenAI__Endpoint=${AZURE_OPENAI_ENDPOINT:-https://mcp-ai.openai.azure.us/}
- Gateway__AzureOpenAI__DeploymentName=${AZURE_OPENAI_DEPLOYMENT:-gpt-4o}
# Git Sync Configuration
- GitSync__GitHubToken=${GITHUB_TOKEN:-}
- GitSync__AzureDevOpsToken=${AZURE_DEVOPS_TOKEN:-}
- GitSync__DefaultSyncIntervalMinutes=${GIT_SYNC_INTERVAL:-15}
- GitSync__AutoSyncEnabled=${GIT_AUTO_SYNC_ENABLED:-true}
- Logging__LogLevel__Default=Information
- Logging__LogLevel__Microsoft=Warning
ports:
- "5050:5050"
healthcheck:
test: ["CMD-SHELL", "curl -f http://localhost:5050/api/templates || exit 1"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
volumes:
- platform-logs:/app/logs
networks:
- platform-network
# Admin Client (Blazor WASM Web UI for Platform Admins)
platform-admin-client:
build:
context: .
dockerfile: src/Platform.Engineering.Copilot.Admin.Client/Dockerfile
target: final
image: platform-engineering-copilot-admin-client:latest
container_name: pec-admin-client
hostname: platform-admin-client
restart: unless-stopped
depends_on:
platform-admin-api:
condition: service_started
ports:
- "5003:80"
healthcheck:
test: ["CMD", "wget", "-q", "--spider", "http://localhost:80/"]
interval: 30s
timeout: 10s
retries: 3
start_period: 10s
networks:
- platform-network
# Optional: Nginx Reverse Proxy (uncomment to use)
# nginx:
# image: nginx:alpine
# container_name: pec-nginx
# restart: unless-stopped
# depends_on:
# - platform-mcp
# - platform-chat
# - platform-admin-api
# - platform-admin-client
# ports:
# - "80:80"
# - "443:443"
# volumes:
# - ./nginx.conf:/etc/nginx/nginx.conf:ro
# networks:
# - platform-network