Skip to content

Commit 42b9639

Browse files
committed
draft docs to run stdio server with holmes
1 parent f632bc0 commit 42b9639

1 file changed

Lines changed: 149 additions & 0 deletions

File tree

docs/configuration/holmesgpt/remote_mcp_servers.rst

Lines changed: 149 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,155 @@ Example : MCP server configuration
4141
4242
helm upgrade robusta robusta/robusta --values=generated_values.yaml --set clusterName=<YOUR_CLUSTER_NAME>
4343
44+
45+
Example : Working with Stdio MCP servers
46+
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
47+
48+
MCP currently supports three transport mechanisms: stdio, Server-Sent Events (SSE), and Streamable HTTP.
49+
At this time, HolmesGPT is compatible only with MCP servers that use SSE.
50+
However, many existing MCP servers—such as Dynatrace MCP—rely exclusively on the stdio transport.
51+
To overcome this incompatibility, tools like Supergateway can act as a bridge by converting stdio-based MCPs into SSE-compatible endpoints.
52+
53+
For this demo we will use
54+
* `Dynatrace MCP <https://github.com/dynatrace-oss/dynatrace-mcp>`_ .
55+
* `Supergateway <https://github.com/supercorp-ai/supergateway>`_ - runs MCP stdio-based servers over SSE.
56+
57+
Check out supergatway docs to find out other useful flags.
58+
59+
1. Run stdio MCP as SSE
60+
""""""""""""""""""""""""""""""
61+
.. md-tab-set::
62+
63+
.. md-tab-item:: Docker
64+
65+
This command runs the Dynatrace MCP server locally via Docker using Supergateway to wrap it with SSE support.
66+
Credentials (e.g., API keys) should be stored in a .env file passed to Docker using --env-file.
67+
you can change `"npx -y @dynatrace-oss/dynatrace-mcp-server@latest /"` to your specific MCP.
68+
69+
.. code-block:: shell
70+
71+
docker run --env-file .env -it --rm -p 8003:8003 supercorp/supergateway \
72+
--stdio "npx -y @dynatrace-oss/dynatrace-mcp-server@latest /" \
73+
--port 8003 \
74+
--logLevel debug
75+
76+
Once the container starts, you should see logs similar to:
77+
78+
.. code-block:: shell
79+
80+
[supergateway] Starting...
81+
[supergateway] Supergateway is supported by Supermachine (hosted MCPs) - https://supermachine.ai
82+
[supergateway] - outputTransport: sse
83+
[supergateway] - Headers: (none)
84+
[supergateway] - port: 8003
85+
[supergateway] - stdio: npx -y @dynatrace-oss/dynatrace-mcp-server@latest /
86+
[supergateway] - ssePath: /sse
87+
[supergateway] - messagePath: /message
88+
[supergateway] - CORS: disabled
89+
[supergateway] - Health endpoints: (none)
90+
[supergateway] Listening on port 8003
91+
[supergateway] SSE endpoint: http://localhost:8003/sse
92+
[supergateway] POST messages: http://localhost:8003/message
93+
94+
.. md-tab-item:: Kubernetes Pod
95+
96+
| This will run dynatrace MCP server as a pod in your cluster.
97+
| credentials are passed as env vars.
98+
99+
.. code-block:: yaml
100+
101+
apiVersion: v1
102+
kind: Pod
103+
metadata:
104+
name: dynatrace-mcp
105+
labels:
106+
app: dynatrace-mcp
107+
spec:
108+
containers:
109+
- name: supergateway
110+
image: supercorp/supergateway
111+
env:
112+
- name: DT_ENVIRONMENT
113+
value: https://abcd1234.apps.dynatrace.com
114+
- name: OAUTH_CLIENT_ID
115+
value: dt0s02.SAMPLE
116+
- name: OAUTH_CLIENT_SECRET
117+
valueFrom:
118+
secretKeyRef:
119+
name: dynatrace-credentials
120+
key: client_secret
121+
ports:
122+
- containerPort: 8003
123+
args:
124+
- "--stdio"
125+
- "npx -y @dynatrace-oss/dynatrace-mcp-server@latest /"
126+
- "--port"
127+
- "8003"
128+
- "--logLevel"
129+
- "debug"
130+
stdin: true
131+
tty: true
132+
---
133+
apiVersion: v1
134+
kind: Service
135+
metadata:
136+
name: dynatrace-mcp
137+
spec:
138+
selector:
139+
app: dynatrace-mcp
140+
ports:
141+
- protocol: TCP
142+
port: 8003
143+
targetPort: 8003
144+
type: ClusterIP
145+
146+
147+
2. Add MCP server to holmes config.
148+
""""""""""""""""""""""""""""""""""""""
149+
150+
With the MCP server running in SSE mode, we need to let HolmesGPT know of the mcp server.
151+
Use this config according to your use case.
152+
153+
**Configuration:**
154+
155+
.. md-tab-set::
156+
157+
.. md-tab-item:: Robusta Helm Chart
158+
159+
**Helm Values:**
160+
161+
.. code-block:: yaml
162+
163+
holmes:
164+
mcp_servers:
165+
mcp_server_1:
166+
description: "Dynatrace observability platform. Bring real-time observability data directly into your development workflow."
167+
url: "http://dynatrace-mcp.default.svc.cluster.local:8003"
168+
169+
170+
Update your Helm values with the provided YAML configuration, then apply the changes with Helm upgrade:
171+
172+
.. code-block:: bash
173+
174+
helm upgrade robusta robusta/robusta --values=generated_values.yaml --set clusterName=<YOUR_CLUSTER_NAME>
175+
176+
After the deployment is complete, you can open the HolmesGPT chat in the Robusta SaaS UI and ask questions like *Using dynatrace what issues do I have in my cluster?*.
44177

178+
.. md-tab-item:: Holmes CLI
179+
180+
Use a config file, and pass it when running cli commands.
45181

182+
**custom_toolset.yaml:**
183+
184+
.. code-block:: yaml
185+
186+
mcp_servers:
187+
mcp_server_1:
188+
description: "Dynatrace observability platform. Bring real-time observability data directly into your development workflow."
189+
url: "http://localhost:8003/sse"
190+
191+
You can now use Holmes via the CLI with your configured MCP server. For example:
192+
193+
.. code-block:: bash
46194
195+
holmes ask -t custom_toolset.yaml "Using dynatrace what issues do I have in my cluster?"

0 commit comments

Comments
 (0)