detain/myadmin-cpanel-webhosting
Composer 安装命令:
composer require detain/myadmin-cpanel-webhosting
包简介
MyAdmin cPanel Webhosting Plugin - Provides cPanel and WHM integration for the MyAdmin control panel, including account provisioning, DNS management, reseller configuration, and XML-API client functionality.
README 文档
README
A MyAdmin plugin that provides full cPanel and WHM integration for webhosting management. This package handles account provisioning, suspension, reactivation, termination, DNS zone management, reseller configuration, package management, and SSL certificate operations through the cPanel XML-API.
Features
- Account Management - Create, suspend, unsuspend, and terminate cPanel hosting accounts
- Reseller Support - Full reseller account setup with ACL configuration and account limits
- DNS Management - Add, edit, and remove DNS zones and records
- Package Management - Create, edit, delete, and list hosting packages
- SSL Certificate Management - Generate, install, and list SSL certificates
- Auto-Login - API endpoint for automatic cPanel login via session tokens
- XML-API Client - Complete PHP client for the cPanel/WHM XML-API with curl and fopen support
- Event-Driven Architecture - Integrates with Symfony EventDispatcher for modular hook-based operation
Installation
Install via Composer:
composer require detain/myadmin-cpanel-webhosting
Usage
Plugin Registration
The plugin registers event hooks automatically through the getHooks() method:
use Detain\MyAdminCpanel\Plugin; $hooks = Plugin::getHooks(); // Returns hook mappings for: settings, activate, reactivate, // deactivate, terminate, api.register, function.requirements, ui.menu
XML-API Client
The included xmlapi class provides direct access to the cPanel/WHM XML-API:
$whm = new xmlapi('your-server-ip'); $whm->set_port('2087'); $whm->set_protocol('https'); $whm->set_output('json'); $whm->hash_auth('root', $accessHash); // List accounts $accounts = $whm->listaccts(); // Create an account $whm->createacct([ 'username' => 'newuser', 'password' => 'securepass', 'domain' => 'example.com', ]);
Running Tests
composer install vendor/bin/phpunit
To generate a coverage report:
vendor/bin/phpunit --coverage-text
License
This package is licensed under the LGPL-2.1 license.
detain/myadmin-cpanel-webhosting 适用场景与选型建议
detain/myadmin-cpanel-webhosting 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 2.14k 次下载、GitHub Stars 达 14, 最近一次更新时间为 2017 年 06 月 08 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「administration」 「cpanel」 「webhosting」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 detain/myadmin-cpanel-webhosting 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 detain/myadmin-cpanel-webhosting 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 detain/myadmin-cpanel-webhosting 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
A Symfony bundle for chameleon-system/sanitycheck
Laravel cPanel/WHM API Package.
Notadd's Administration Module.
Dynamically Laravel CRUD administration with automatic database migrations
Cpanel Licensing Class
Cpanel Licensing Class
统计信息
- 总下载量: 2.14k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 14
- 点击次数: 13
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: LGPL-2.1-only
- 更新时间: 2017-06-08