-
Notifications
You must be signed in to change notification settings - Fork 23
feat: adds "thv inspector" to run an inspector for an MCP server #381
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: ChrisJBurns <[email protected]>
Signed-off-by: ChrisJBurns <[email protected]>
Signed-off-by: ChrisJBurns <[email protected]>
@@ -30,7 +30,7 @@ go.work | |||
|
|||
.roo/ | |||
^thv$ | |||
|
|||
.claude/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's move this to a separate PR.
inspectorCommand := &cobra.Command{ | ||
Use: "inspector [container-name]", | ||
Short: "Output the logs of an MCP server", | ||
Long: `Output the logs of an MCP server managed by Vibe Tool.`, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not accurate.
|
||
// Define fixed port configuration for the inspector container | ||
clientUIPort := "6274" | ||
mcpProxyPort := "6277" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we make these configurable flags? These can be the defaults.
{ | ||
HostIP: "0.0.0.0", | ||
HostPort: mcpProxyPort, | ||
}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should we default to ipv4 localhost?
@@ -54,6 +54,9 @@ const ( | |||
|
|||
// TransportTypeSSE represents the SSE transport. | |||
TransportTypeSSE TransportType = "sse" | |||
|
|||
// TransportTypeBridge represents the bridge network mode for container networking. | |||
TransportTypeBridge TransportType = "bridge" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's this piece? I don't think we'll be supporting a bridge transport.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I'll be removing this. It was added simply because the Inspector server doesn't fit into the sse or stdio category. Just wanted to push what I had up and draft PR it so I can checkout other branches in the meantime.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
aha! Let's document that a little better. If it really doesn't fit we can re-evaluate.
Description
Up to now we've had to do some nice
curl
backflips (or worse) to debug MCP servers. This PR adds the ability to run an MCP Inspector container that is pre-configured to point to the specified MCP server.To run:
thv inspector <server-name>
. Then go tohttp://localhost:6274/?transport=sse&serverUrl=http://host.docker.internal:<port>/sse
ensuring to enter the correct port for your MCP server.Todo
npx://
until this issue is closed and the official image is usable (and make specifying the version flag driving)sse
orstdio
categoryInspector is ready to inspect your MCP server, go to http://localhost:6274/?transport=sse&serverUrl=http://host.docker.internal:59278/sse#fetch
.host.docker.internal
works nicely. We may have to do some extra stuff for the Linux users.Ref: #25