nomad-mcp is a read-only MCP server for HashiCorp Nomad built with the official Go MCP SDK and the official Nomad API client.
Note
This project was developed via agentic / vibe coding
The initial implementation targets stdio transport and read-only inspection workflows.
Supported tools:
get_cluster_statuslist_regionslist_namespaceslist_nodesget_nodelist_jobsget_jobget_job_scale_statusget_job_evaluationsget_job_allocationsget_job_serviceslist_deploymentsget_deploymentlist_allocationsget_allocationget_allocation_checks
list_jobs now includes each job's meta map and a stable meta_summary string so clients can answer discovery questions from a single tool call.
Supported resources:
nomad://cluster/summarynomad://jobs/{namespace}/{job_id}/summarynomad://jobs/{namespace}/{job_id}/specnomad://jobs/{namespace}/{job_id}/evaluationsnomad://allocs/{allocation_id}/statusnomad://allocs/{allocation_id}/checksnomad://allocs/{allocation_id}/logs/{task_name}/{stream}nomad://nodes/{node_id}/statusnomad://nodes/{node_id}/allocationsnomad://deployments/{deployment_id}nomad://evaluations/{evaluation_id}
Supported prompts:
debug_allocationexplain_evaluationdiagnose_deploymentinvestigate_nodeexplain_job
The server uses Nomad's standard environment variables through github.com/hashicorp/nomad/api.DefaultConfig().
Operational logs are emitted with Go's log/slog package to stderr, so they do not interfere with the MCP stdio protocol on stdout. Set NOMAD_MCP_LOG_LEVEL to debug, info, warn, or error to adjust verbosity.
Common variables:
NOMAD_ADDRNOMAD_TOKENNOMAD_NAMESPACENOMAD_REGIONNOMAD_CACERTNOMAD_CAPATHNOMAD_CLIENT_CERTNOMAD_CLIENT_KEYNOMAD_TLS_SERVER_NAMENOMAD_SKIP_VERIFY
Per-tool inputs can override namespace, region, pagination, filtering, and stale-read behavior where the underlying Nomad endpoint supports those options.
For discovery-style questions, prefer list_jobs first. The filter input accepts native Nomad filter expressions, for example:
Name matches "financial"Meta.department == "financial"
That makes questions like "what financial jobs are there" answerable without post-processing MCP output with shell tools.
Build the server:
go build ./cmd/nomad-mcpRun it directly over stdio:
./nomad-mcpBuild the image:
docker build -t nomad-mcp .Run it over stdio:
docker run --rm -i \
-e NOMAD_ADDR=https://nomad.example.com \
-e NOMAD_TOKEN=... \
nomad-mcpThe container uses the same NOMAD_* environment variables as the local binary.
- This MVP does not perform writes.
- This MVP does not expose event streams or blocking-query watch semantics.
- Allocation logs are exposed only as bounded static tails through resources and prompts. Follow mode and filesystem browsing are still excluded.