MCP server
ELM includes an optional, read-only Model Context Protocol (MCP) server. It exposes selected ELM data to MCP clients through stateless Streamable HTTP.
Enable the service
Set the following in /etc/elm-server.conf:
ENABLE_MCP=true
MCP_BIND=127.0.0.1
MCP_PORT=8085
Then restart ELM:
sudo systemctl restart elm-server
The Streamable HTTP handler is served at the MCP listener root. The service binds to loopback by default because client credentials travel in the Authorization header. Expose it beyond the ELM host only through a TLS-protected, access-controlled endpoint.
For an MCP-only node with ENABLE_WEB=false, set ELM_API_URL to the remote ELM web address.
Authentication and permissions
The MCP service stores no ELM credential. Each client sends an HTTP Basic Authorization header for its own ELM user. The service forwards that header to the REST API, so results are limited by the user's permissions.
Use a dedicated ELM account with only the required view permissions. The MCP tools issue only REST API GET requests and cannot change ELM state.
Available tools
The service provides list and detail tools for:
- Hosts and host groups.
- Sources and source packages.
- Content views, content-view packages, and snapshots.
- Kickstarts.
List tools accept optional page, limit, and search arguments. ELM defaults to 50 rows per page and caps a page at 200 rows.
Related
- Explore the underlying resources with the API.
- Assign least-privilege access with Users, teams, and permissions.