-
Notifications
You must be signed in to change notification settings - Fork 79
Expand file tree
/
Copy pathdocker-compose.yaml
More file actions
174 lines (166 loc) · 5.57 KB
/
docker-compose.yaml
File metadata and controls
174 lines (166 loc) · 5.57 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
services:
# Mock MCP server for testing
mcp-mock-server:
build:
context: .
dockerfile: dev-tools/mcp-mock-server/Dockerfile
container_name: mcp-mock-server
ports:
- "3000:3000"
networks:
- lightspeednet
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:3000/"]
interval: 5s
timeout: 3s
retries: 3
start_period: 5s
# Red Hat llama-stack distribution with FAISS
llama-stack:
build:
context: .
dockerfile: test.containerfile
platform: linux/amd64
container_name: llama-stack
ports:
- "8321:8321" # Expose llama-stack on 8321 (adjust if needed)
depends_on:
mock-tls-inference:
condition: service_healthy
volumes:
- ./run.yaml:/opt/app-root/run.yaml:z
- ${GCP_KEYS_PATH:-./tmp/.gcp-keys-dummy}:/opt/app-root/.gcp-keys:ro
- ./lightspeed-stack.yaml:/opt/app-root/lightspeed-stack.yaml:ro
- llama-storage:/opt/app-root/src/.llama/storage
- ./tests/e2e/rag:/opt/app-root/src/.llama/storage/rag:z
- mock-tls-certs:/certs:ro
environment:
- BRAVE_SEARCH_API_KEY=${BRAVE_SEARCH_API_KEY:-}
- TAVILY_SEARCH_API_KEY=${TAVILY_SEARCH_API_KEY:-}
# OpenAI
- OPENAI_API_KEY=${OPENAI_API_KEY}
- E2E_OPENAI_MODEL=${E2E_OPENAI_MODEL:-gpt-4o-mini}
# Azure Entra ID credentials (AZURE_API_KEY is passed via provider_data at request time)
- TENANT_ID=${TENANT_ID:-}
- CLIENT_ID=${CLIENT_ID:-}
- CLIENT_SECRET=${CLIENT_SECRET:-}
# RHAIIS
- RHAIIS_URL=${RHAIIS_URL}
- RHAIIS_PORT=${RHAIIS_PORT}
- RHAIIS_API_KEY=${RHAIIS_API_KEY}
- RHAIIS_MODEL=${RHAIIS_MODEL}
# RHEL AI
- RHEL_AI_URL=${RHEL_AI_URL}
- RHEL_AI_PORT=${RHEL_AI_PORT}
- RHEL_AI_API_KEY=${RHEL_AI_API_KEY}
- RHEL_AI_MODEL=${RHEL_AI_MODEL}
# VertexAI
- GOOGLE_APPLICATION_CREDENTIALS=${GOOGLE_APPLICATION_CREDENTIALS:-}
- VERTEX_AI_PROJECT=${VERTEX_AI_PROJECT:-}
- VERTEX_AI_LOCATION=${VERTEX_AI_LOCATION:-}
# WatsonX
- WATSONX_BASE_URL=${WATSONX_BASE_URL:-}
- WATSONX_PROJECT_ID=${WATSONX_PROJECT_ID:-}
- WATSONX_API_KEY=${WATSONX_API_KEY:-}
- LITELLM_DROP_PARAMS=true
# AWS Bedrock
- AWS_BEARER_TOKEN_BEDROCK=${AWS_BEARER_TOKEN_BEDROCK:-}
# Enable debug logging if needed
- LLAMA_STACK_LOGGING=${LLAMA_STACK_LOGGING:-}
# FAISS test
- FAISS_VECTOR_STORE_ID=${FAISS_VECTOR_STORE_ID:-}
networks:
- lightspeednet
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8321/v1/health"]
interval: 10s # how often to run the check
timeout: 5s # how long to wait before considering it failed
retries: 3 # how many times to retry before marking as unhealthy
start_period: 15s # time to wait before starting checks
lightspeed-stack:
build:
context: .
dockerfile: Containerfile
container_name: lightspeed-stack
ports:
- "8080:8080"
volumes:
- ./lightspeed-stack.yaml:/app-root/lightspeed-stack.yaml:z
- ./tests/e2e/secrets/mcp-token:/tmp/mcp-token:ro
- ./tests/e2e/secrets/invalid-mcp-token:/tmp/invalid-mcp-token:ro
environment:
- OPENAI_API_KEY=${OPENAI_API_KEY}
# Azure Entra ID credentials (AZURE_API_KEY is obtained dynamically)
- TENANT_ID=${TENANT_ID:-}
- CLIENT_ID=${CLIENT_ID:-}
- CLIENT_SECRET=${CLIENT_SECRET:-}
# FAISS vector store ID (used by inline RAG config)
- FAISS_VECTOR_STORE_ID=${FAISS_VECTOR_STORE_ID:-}
depends_on:
llama-stack:
condition: service_healthy
mcp-mock-server:
condition: service_healthy
mock-mcp:
condition: service_healthy
networks:
- lightspeednet
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8080/liveness"]
interval: 10s # how often to run the check
timeout: 5s # how long to wait before considering it failed
retries: 3 # how many times to retry before marking as unhealthy
start_period: 5s # time to wait before starting checks
# Mock JWKS server for RBAC E2E tests
mock-jwks:
build:
context: ./tests/e2e/mock_jwks_server
dockerfile: Dockerfile
container_name: mock-jwks
ports:
- "8000:8000"
networks:
- lightspeednet
healthcheck:
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:8000/health')"]
interval: 5s
timeout: 3s
retries: 3
start_period: 2s
mock-mcp:
build:
context: ./tests/e2e/mock_mcp_server
dockerfile: Dockerfile
container_name: mock-mcp
ports:
- "3001:3001"
networks:
- lightspeednet
healthcheck:
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:3001/health')"]
interval: 5s
timeout: 3s
retries: 3
start_period: 2s
# Mock TLS inference server for TLS E2E tests
mock-tls-inference:
build:
context: ./tests/e2e/mock_tls_inference_server
dockerfile: Dockerfile
container_name: mock-tls-inference
networks:
- lightspeednet
volumes:
- mock-tls-certs:/certs
healthcheck:
test: ["CMD", "python", "-c", "import urllib.request,ssl;c=ssl.create_default_context();c.check_hostname=False;c.verify_mode=ssl.CERT_NONE;urllib.request.urlopen('https://localhost:8443/health',context=c)"]
interval: 5s
timeout: 3s
retries: 3
start_period: 5s
volumes:
llama-storage:
mock-tls-certs:
networks:
lightspeednet:
driver: bridge