by kocierik
mcp-nomad is a Golang-based MCP (Model Context Protocol) server designed to manage HashiCorp Nomad clusters. It provides a comprehensive set of tools for interacting with Nomad, enabling programmatic control over various aspects of cluster operations.
mcp-nomad is a server that provides a set of tools for managing Nomad clusters through the Model Context Protocol (MCP). It is written in Go and allows for programmatic interaction with Nomad, offering a wide range of functionalities for cluster management.
mcp-nomad can be used in several ways:
npx @modelcontextprotocol/inspector npx @kocierik/mcp-nomad
to browse with the Inspector.claude_desktop_config.json
or using installation tools like Smithery (npx -y @smithery/cli install @kocierik/mcp-nomad --client claude
) or mcp-get (npx @michaellatman/mcp-get@latest install @kocierik/mcp-nomad
).npm install -g @kocierik/mcp-nomad
.go get github.com/kocierik/mcp-nomad
and go install github.com/kocierik/mcp-nomad
.Configuration options include specifying the Nomad server address (-nomad-addr
), port for SSE server (-port
), and transport type (-transport
). Environment variables like NOMAD_ADDR
and NOMAD_TOKEN
can also be set.
mcp-nomad offers extensive features for managing Nomad clusters, categorized as follows:
-nomad-addr
option or the NOMAD_ADDR
environment variable. An optional NOMAD_TOKEN
can be used for ACL authentication.NOMAD_ADDR
to be set to http://host.docker.internal:4646
.Example variable operations:
# List variables in a namespace
list_variables namespace="my-namespace" prefix="my/path" per_page=10
# Get a specific variable
get_variable path="my/path" namespace="my-namespace"
# Create a variable
create_variable path="my/path" key="username" value="john" namespace="my-namespace"
# Delete a variable
delete_variable path="my/path" namespace="my-namespace"
To use the latest published version with Inspector:
npx @modelcontextprotocol/inspector npx @kocierik/mcp-nomad
-nomad-addr string
Nomad server address (default "http://localhost:4646")
-port string
Port for SSE server (default "8080")
-transport string
Transport type (stdio or sse) (default "stdio")
NOMAD_ADDR
: Nomad HTTP API address (default: http://localhost:4646)NOMAD_TOKEN
: Nomad ACL token (optional)https://github.com/user-attachments/assets/731621d7-0acf-4045-bacc-7b34a7d83648
Smithery | mcp-get | Pre-built NPM | Pre-built in Github | From sources | Using Docker | |
---|---|---|---|---|---|---|
Claude Setup | Auto | Auto | Manual | Manual | Manual | Manual |
Prerequisite | Node.js | Node.js | Node.js | None | Golang | Docker |
npx -y @smithery/cli install @kocierik/mcp-nomad --client claude
npx @michaellatman/mcp-get@latest install @kocierik/mcp-nomad
npm install -g @kocierik/mcp-nomad
Update your claude_desktop_config.json
:
{
"mcpServers": {
"mcp_nomad": {
"command": "mcp-nomad",
"args": [],
"env": {
"NOMAD_TOKEN": "${NOMAD_TOKEN}",
"NOMAD_ADDR": "${NOMAD_ADDR}"
}
}
}
}
Download the binary and configure Claude Desktop like so:
{
"mcpServers": {
"mcp_nomad": {
"command": "mcp-nomad",
"args": [],
"env": {
"NOMAD_TOKEN": "${NOMAD_TOKEN}",
"NOMAD_ADDR": "${NOMAD_ADDR}"
}
}
}
}
go get github.com/kocierik/mcp-nomad
go install github.com/kocierik/mcp-nomad
docker run -i --rm --network=host kocierik/mcpnomad-server:latest
docker run -i --rm \
-e NOMAD_ADDR=http://host.docker.internal:4646 \
kocierik/mcpnomad-server:latest
{
"mcpServers": {
"mcp_nomad": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"-e", "NOMAD_TOKEN=secret-token-acl-optional",
"-e", "NOMAD_ADDR=http://host.docker.internal:4646",
"mcpnomad/server:latest"
]
}
}
}
{
"mcpServers": {
"mcp_nomad": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"-e",
"NOMAD_ADDR=http://172.17.0.1:4646",
"-e", "NOMAD_TOKEN=secret-token-acl-optional",
"kocierik/mcpnomad-server:latest"
]
}
}
}
This project is licensed under the MIT License - see the LICENSE file for details.
Reviews feature coming soon
Stay tuned for community discussions and feedback