portainer-mcp
Verified Safeby caffeineflo
Overview
Enables AI assistants to manage Docker containers and resources through the Portainer API.
Installation
docker run --rm -e PORTAINER_URL=https://portainer.example.com -e PORTAINER_API_KEY=ptr_your_key_here ghcr.io/caffeineflo/portainer-mcp:latestEnvironment Variables
- PORTAINER_URL
- PORTAINER_API_KEY
- PORTAINER_WRITE_ENABLED
Security Notes
Write operations are explicitly disabled by default (`PORTAINER_WRITE_ENABLED=false`) and must be enabled via an environment variable, significantly reducing potential harm from accidental or malicious AI actions. Input validation via Zod is used for all tool arguments. Sensitive API keys are passed via environment variables, not hardcoded. The `PortainerClient` handles common HTTP errors (401, 403, 404) and connection issues gracefully. Docker log stripping handles multiplexed streams correctly to prevent data interpretation issues.
Similar Servers
podman-mcp-server
A Model Context Protocol (MCP) server that enables AI assistants to interact with container runtimes like Podman and Docker for container management tasks.
mcp-kubernetes
Enables AI assistants to interact with and debug Kubernetes clusters by translating natural language requests into Kubernetes operations.
mcp-helm
Provides a Model Context Protocol (MCP) server for AI assistants to interact with Helm repositories and charts without requiring a local Helm installation.
docker-mcp-server
A Model Context Protocol (MCP) server for containerized execution and file operations, enabling AI assistants to interact with a Docker environment via HTTP.