detain/myadmin-directadmin-licensing
Composer 安装命令:
composer require detain/myadmin-directadmin-licensing
包简介
DirectAdmin Licensing plugin for the MyAdmin ecosystem. Provides activation, deactivation, IP management, and OS modification for DirectAdmin server and VPS licenses.
README 文档
README
A MyAdmin plugin that integrates DirectAdmin license management into the billing and provisioning system. It supports selling, activating, deactivating, and managing both paid and free-tier DirectAdmin server and VPS licenses via the DirectAdmin API.
Features
- Automated license provisioning when customers purchase DirectAdmin licenses
- License activation and deactivation through the DirectAdmin API
- IP address change support for migrating licenses between servers
- Free-tier license management for qualifying VPS packages
- OS type detection and mapping for license compatibility
- Admin panel integration with license management menus and settings
- Payment processing for newly created licenses
Installation
Install with Composer:
composer require detain/myadmin-directadmin-licensing
Usage
This package is designed to run within the MyAdmin hosting management platform. The Plugin class registers event hooks that the MyAdmin framework dispatches during license lifecycle operations.
Plugin Registration
The plugin is auto-discovered by MyAdmin through Composer's plugin installer. It registers handlers for:
licenses.settings-- Admin configuration fields (API credentials, stock settings)licenses.activate/licenses.reactivate-- License provisioning on purchaselicenses.deactivate/licenses.deactivate_ip-- License cancellationfunction.requirements-- Lazy-loading of procedural API functions
Available Functions
| Function | Description |
|---|---|
get_directadmin_license_types() |
Returns supported OS type mappings |
activate_directadmin() |
Creates and activates a paid license |
deactivate_directadmin() |
Cancels an active license |
directadmin_deactivate() |
Alias that delegates to deactivate_directadmin() |
get_directadmin_licenses() |
Lists all licenses on the account |
get_directadmin_license() |
Fetches a single license record by ID |
get_directadmin_license_by_ip() |
Finds a license by IP address |
directadmin_ip_to_lid() |
Resolves an IP address to a license ID |
directadmin_makepayment() |
Processes payment for a newly created license |
directadmin_get_os_list() |
Retrieves available OS types from the DA API |
directadmin_get_products() |
Retrieves the product catalog from the DA API |
directadmin_modify_os() |
Changes the OS type of a license |
activate_free_license() |
Provisions a free-tier license |
delete_free_license() |
Removes a free-tier license |
Running Tests
composer install vendor/bin/phpunit
To generate a coverage report:
vendor/bin/phpunit --coverage-html build/coverage
License
This package is licensed under the LGPL-2.1 license.
detain/myadmin-directadmin-licensing 适用场景与选型建议
detain/myadmin-directadmin-licensing 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 2.33k 次下载、GitHub Stars 达 6, 最近一次更新时间为 2017 年 05 月 25 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「administration」 「license」 「directadmin」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 detain/myadmin-directadmin-licensing 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 detain/myadmin-directadmin-licensing 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 detain/myadmin-directadmin-licensing 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
HiDev plugin for license generation
A Symfony bundle for chameleon-system/sanitycheck
PHP client library to manage DirectAdmin control panel servers.
Notadd's Administration Module.
Dynamically Laravel CRUD administration with automatic database migrations
Cpanel Licensing Class
统计信息
- 总下载量: 2.33k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 6
- 点击次数: 16
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: LGPL-2.1-only
- 更新时间: 2017-05-25