Skip to main content
Glama

Plesk MCP 服务器

PleskMCP 服务器 允许管理员使用各种 AI 代理和应用程序来管理其 Plesk 服务器。它基于 Plesk REST API 和 WP Toolkit REST API 构建,提供了核心管理功能,以及通过 shell 命令管理服务器和向服务器上传文件的能力。

该 MCP 服务器在您的本地机器上运行,因此重要信息不会离开您的环境。

Plesk 要求

该 MCP 服务器预计支持任何较新的 Plesk 版本(没有严格限制)以及 Plesk 支持的任何操作系统(Linux 或 Windows)。但是,它仅在 Plesk Obsidian 18.0.76 上进行了测试,因此建议使用 受支持的 Plesk 版本

显然,服务器上的 API 访问权限不得被禁用。

Related MCP server: cPanel MCP Server

MCP 服务器要求

您需要 uv Python 包管理器来运行该服务器。有关安装说明,请参阅 官方文档

使用方法

在您的 VS Code mcp.json 或等效配置(在其他代理或应用程序中)中使用如下配置来配置服务器:

{
    "servers": {
        "plesk": {
            "command": "uvx",
            "args": [
                "plesk-mcp@latest"
            ],
            "env": {
                // Base URL of your Plesk server. May include port.
                // If you don't have a valid TLS certificate or want to use HTTP,
                // add the --insecure flag to the args above.
                // However, this is not recommended as you credentials may be leaked as a result.
                "PLESK_HOST": "https://plesk.example.net:8443",
                // API key (recommended).
                // Create via `plesk bin secret_key --create -description 'Plesk MCP'` on the server.
                "PLESK_API_KEY": "00000000-0000-0000-0000-000000000000",
                // Alternatively, you can use username and password.
                "PLESK_USERNAME": "admin",
                "PLESK_PASSWORD": "passwd"
            }
        }
    }
}

如果您的代理或应用程序支持,您可能希望使用 env 文件(例如通过 "envFile" 参数)。这将避免将凭据直接放入配置文件中。

有关可用选项和环境变量的详细信息,请参阅 uvx plesk-mcp@latest --help

推荐用法

为了获得更好的表现,建议将此 MCP 服务器与文档 MCP 服务器结合使用。选择 plesk-local-docs-mcpplesk-remote-docs-mcp。这将允许代理在需要时获取有关 Plesk 使用情况的更准确信息。

如果需要,您还可以同时附加多个 Plesk 服务器(例如用于管理多台服务器)。

以下是配置示例:

{
    "servers": {
        "plesk-docs": {
            "command": "uvx",
            "args": [
                "plesk-local-docs-mcp@latest"
            ],
            "env": {
                "OPENAI_API_KEY": "sk-..."
            }
        },
        "plesk1": {
            "command": "uvx",
            "args": [
                "plesk-mcp@latest"
            ],
            "env": {
                "PLESK_HOST": "https://plesk1.example.net:8443",
                "PLESK_API_KEY": "00000000-0000-0000-0000-000000000000"
            }
        },
        "plesk2": {
            "command": "uvx",
            "args": [
                "plesk-mcp@latest"
            ],
            "env": {
                "PLESK_HOST": "https://plesk2.example.net",
                "PLESK_USERNAME": "admin",
                "PLESK_PASSWORD": "passwd"
            }
        }
    }
}

开发

MCP 服务器运行命令:

uv run plesk-mcp --log-level debug --insecure

提交前:

uv run ruff format
uv run ruff check --fix
uv run mypy .

发布:

uv build --clear
uv publish
mcp-publisher publish

测试

使用 Plesk Docker 镜像

如果您没有 Plesk 实例但想测试此 MCP 服务器,可以使用 Plesk Docker 镜像 代替:

docker run -d --rm --tmpfs /tmp --tmpfs /run --tmpfs /run/lock -v /sys/fs/cgroup:/sys/fs/cgroup --cgroupns host -p 80:80 -p 443:443 -p 8880:8880 -p 8443:8443 --name plesk plesk/plesk

Docker 镜像启动不是即时的,因此在尝试连接之前请等待一分钟左右。

然后将 MCP 服务器配置为:

{
    "servers": {
        "plesk": {
            "command": "uvx",
            "args": [
                "plesk-mcp@latest",
                "--insecure"
            ],
            "env": {
                "PLESK_HOST": "https://localhost:8443",
                "PLESK_PASSWORD": "changeme1Q**"
            }
        }
    }
}

无 Plesk 服务器(演示模式)

或者,从源代码以演示模式运行(使用模拟响应):

{
    "servers": {
        "plesk": {
            "command": "uv",
            "args": [
                "run",
                "plesk-mcp"
            ],
            "env": {
                "PLESK_HOST": "https://linux.demo.example.net",
                "PLESK_API_KEY": "-"
            }
        }
    }
}
Install Server
A
license - permissive license
A
quality
D
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • A
    license
    Not graded
    quality
    D
    maintenance
    Enables AI agents to manage Plesk hosting environments through a set of standardized tools for security, health monitoring, DNS, email, backups, and service management.
    MIT
  • F
    license
    Not graded
    quality
    D
    maintenance
    Enables AI assistants to manage WHM hosting accounts and server administration tasks including account management, server stats, updates, SSL, backups, and email through a secure API.
    10
  • F
    license
    B
    quality
    C
    maintenance
    A comprehensive MCP server for managing cPanel hosting accounts through AI assistants. It supports DNS, email (DKIM/SPF), databases, domains, SSL, PHP, cron jobs, security, Git deployment, and more.
    100
    15

View all related MCP servers

Related MCP Connectors

  • Let AI operate servers without SSH. Choose actions, approve risky changes, and audit every step.

  • Provision and manage a VPS for AI agents over MCP: register, order, get root, control the server.

  • AI-powered design and management for Webflow Sites

View all MCP Connectors

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/FlayedOne/plesk-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server