Back to Home
caffeineflo icon

portainer-mcp

Verified Safe

by caffeineflo

Overview

Enables AI assistants to manage Docker containers and resources through the Portainer API.

Installation

Run Command
docker run --rm -e PORTAINER_URL=https://portainer.example.com -e PORTAINER_API_KEY=ptr_your_key_here ghcr.io/caffeineflo/portainer-mcp:latest

Environment 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

Stats

Interest Score0
Security Score9
Cost ClassMedium
Avg Tokens2000
Stars0
Forks0
Last Update2025-12-17

Tags

PortainerDockerMCPAI AssistantContainer Management