Docker MCP Server
Provides comprehensive Docker container and image management capabilities, including starting/stopping containers, pulling/removing images, deploying Docker Compose stacks, and monitoring container logs and statistics
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Docker MCP Serverlist all running containers and show their status"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
đł Docker MCP Server
Docker Model Context Protocol (MCP) Server - Permite que IAs como Claude gerenciem containers Docker através do protocolo MCP de forma segura e intuitiva.
đ Features
đ§ Gerenciamento completo de containers: Start, stop, restart, logs, estatĂsticas
đŠ Controle de imagens: Pull, remove, verificar atualizaçÔes
đł Docker Compose: Deploy e remoção de stacks via YAML
đ MĂșltiplos servidores: Conectar a vĂĄrios Docker hosts simultĂąneamente
đ Segurança: Socket Unix local ou TCP com TLS
đ Monitoramento: Logs estruturados e mĂ©tricas em tempo real
⥠Integração Claude: Pronto para uso com Claude Code/Desktop
Related MCP server: Docker MCP Server
đ Quick Start
# 1. Navegar para o diretĂłrio
cd /home/marcelo/docker/mcp-docker-server
# 2. Instalar dependĂȘncias
npm install
# 3. Configurar ambiente (opcional)
cp config/.env.example .env
# 4. Iniciar servidor
npm startđ Prerequisites
Node.js >= 18.0.0
Docker Engine funcionando
UsuĂĄrio no grupo
dockerClaude Code ou Claude Desktop
đ ïž Available Tools
Category | Tools | Description |
Containers |
| Gerenciamento completo de containers |
Images |
| Controle de imagens Docker |
Compose |
| Deploy via YAML inline |
Networks/Volumes |
| Visualização de recursos |
Servers |
| Multi-host management |
đ Claude Integration
Método 1: Configuração de projeto
Criar .claude/mcp.json:
{
"servers": {
"docker-local": {
"type": "stdio",
"command": "node",
"args": ["src/index.js"],
"env": {
"DOCKER_SOCKET": "/var/run/docker.sock"
},
"description": "Local Docker management via MCP"
}
}
}Método 2: Claude Desktop global
Ver exemplos em config/claude-desktop-sample.json.
đ Examples
Listar containers via Claude
"Liste todos os containers Docker ativos e parados"Deploy Docker Compose via Claude
"Deploy este Docker Compose:
version: '3.8'
services:
redis:
image: redis:alpine
ports:
- '6379:6379'"Gerenciar container especĂfico
"Reinicie o container 'nginx-proxy' e mostre os logs recentes"đ Project Structure
mcp-docker-server/
âââ src/
â âââ index.js # Servidor principal
âââ scripts/
â âââ start-server.sh # Script de inicialização
â âââ stop-server.sh # Script de parada
âââ config/
â âââ .env.example # Configuração de ambiente
â âââ claude-desktop-sample.json
â âââ env.sample.sh
âââ docs/
â âââ SETUP.md # Documentação completa
âââ logs/ # Logs de execução
âââ .claude/
â âââ mcp.json # Configuração MCP do projeto
âââ package.jsonâïž Configuration
Socket Unix (PadrĂŁo)
DOCKER_SOCKET=/var/run/docker.sockDocker remoto
DOCKER_HOST=192.168.1.10
DOCKER_PORT=2375
DOCKER_PROTOCOL=httpMĂșltiplos servidores
DOCKER_SERVERS=local:socket:/var/run/docker.sock,prod:prod-docker:2376:httpsđ Troubleshooting
Erro de permissĂŁo
sudo usermod -aG docker $USER
newgrp dockerDependĂȘncias
rm -rf node_modules package-lock.json
npm installDebug
export LOG_LEVEL=debug
npm startđ Monitoring
# Logs em tempo real
tail -f logs/server-*.log
# Status bĂĄsico
timeout 5s npm start < /dev/nullđš Security Notes
â ïž IMPORTANTE: O acesso ao socket Docker concede privilĂ©gios equivalentes ao root. Use apenas em ambientes confiĂĄveis.
Socket local: Preferir quando possĂvel
TCP remoto: Sempre usar TLS em produção
Firewall: Limitar acesso Ă s portas Docker
Containers: Revisar imagens antes de executar
đ Documentation
đ Setup Guide - Guia completo de instalação e configuração
đ§ Troubleshooting - Solução de problemas comuns
đ Claude Integration - Integração com Claude
đ ïž Available Tools - Lista completa de ferramentas
đ License
MIT License - Ver arquivo LICENSE para detalhes.
đ€ Contributing
Fork o projeto
Criar feature branch (
git checkout -b feature/nova-funcionalidade)Commit as mudanças (
git commit -am 'Adiciona nova funcionalidade')Push to branch (
git push origin feature/nova-funcionalidade)Abrir Pull Request
â Support
Gostou do projeto? Deixe uma estrela â
Encontrou algum problema? Abra uma issue đ
Criado por: Marcelo Matos
Baseado em: mcp-docker por FlorentB974
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/marcelofmatos/mcp-docker-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server