sandboxmcp

package
v0.0.0-...-73ddf49 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 2, 2026 License: MIT Imports: 17 Imported by: 0

Documentation

Overview

Package sandboxmcp serves the sandbox-management MCP tools mdev exposes to Claude on the host: sandbox_up, sandbox_down, sandbox_exec, sandbox_status, sandbox_events. Auth is the admin bearer token from ~/.config/mdev/config.yml. Tools are namespaced under the `mdev` server name so Claude sees `mcp__mdev__sandbox_up` etc.

Index

Constants

View Source
const MCPPath = "/mcp-admin"

MCPPath is the sandbox-management MCP mount point on the admin port.

Variables

This section is empty.

Functions

This section is empty.

Types

type Server

type Server struct {
	// contains filtered or unexported fields
}

Server is the sandbox-management MCP runtime. Exposed to clients through Handler(). It owns its dependencies and delegates the two stateful features to dedicated, concurrent-safe sub-components: procs (tracked host processes) and events (the recent-event ring).

func NewServer

func NewServer(tun *tunnel.Server, ctrl *controller.Controller, adminToken string) *Server

NewServer constructs the MCP server gated by the given admin token. If ctrl is non-nil, the server consumes controller events for the sandbox_events tool's ring buffer.

func (*Server) Handler

func (s *Server) Handler() http.Handler

Handler returns the HTTP handler to mount at MCPPath. Every request is gated by the admin bearer token.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL