GitHunt
SM

smtozkn06/WHM-Management-Tool

A modern and user-friendly WHM management tool for server administrators. Create and manage MySQL databases and subdomains in bulk through WHM server management interface, and export your data in various formats.

๐Ÿš€ WHM Management Tool

A modern and user-friendly WHM management tool for server administrators. Create and manage MySQL databases and subdomains in bulk through WHM server management interface, and export your data in various formats.

Python
License
Platform
WHM
CI
GitHub release

โœจ Features

๐Ÿ”— WHM Server Management

  • WHM Connection: Server-level management (port 2087) - Full server access required
  • Manage all cPanel accounts from a central interface
  • Secure connection settings with automatic saving
  • Root-level access for comprehensive server management

๐Ÿ—„๏ธ MySQL Database Management

  • Bulk MySQL database creation across all accounts
  • Automatic sequential naming (demo1, demo2, demo3...)
  • Database users and authorization management
  • Bulk deletion of selected databases
  • Full database privilege management

๐ŸŒ Subdomain Management

  • Bulk subdomain creation for any cPanel account
  • Automatic sequential naming (demo1.domain.com, demo2.domain.com...)
  • Physical directory management and cleanup
  • Bulk deletion of selected subdomains
  • Comprehensive subdomain lifecycle management

๐Ÿ“Š Export System

  • TXT Export: database:username:password:subdomain format
  • CSV Export: Excel-compatible CSV file
  • XLSX Export: Full Excel table format
  • Real-time preview of created resources
  • Export only newly created data for easy tracking

๐ŸŽจ Modern Interface

  • Dark theme CustomTkinter interface
  • Real-time status updates and progress tracking
  • Multi-account domain selection
  • User-friendly error messages and validation
  • Compact design optimized for all screen sizes

๐Ÿ“‹ Requirements

  • Python 3.8 or higher
  • WHM root access privileges
  • Internet connection to WHM server

๐Ÿ› ๏ธ Installation

  1. Clone the repository
git clone https://github.com/yourusername/whm-management-tool.git
cd whm-management-tool
  1. Create virtual environment (recommended)
python -m venv venv

# Windows
venv\Scripts\activate

# Linux/macOS
source venv/bin/activate
  1. Install dependencies
pip install -r requirements.txt
  1. Run the application
python main_app.py

Method 2: Install as Package

# Install from source
pip install .

# Or install in development mode
pip install -e .

# Run after installation
whm-management-tool

Method 3: Quick Install (Future PyPI Release)

# This will be available when published to PyPI
pip install whm-management-tool

๐Ÿš€ Usage

1. Establishing WHM Connection

  1. Enter WHM Host (e.g., https://your-server.com:2087)
  2. Enter Username (usually root)
  3. Enter WHM root password
  4. Click "Connect" button

Settings are automatically saved when connection is successful.

2. Domain Selection

  • Domain list loads automatically from all cPanel accounts on the server
  • Select the cPanel account/domain you want to work with from the dropdown
  • All operations will be performed on the selected account

3. Creating MySQL Databases

  1. Go to "MySQL Databases" tab
  2. Enter the number of databases to be created
  3. Click "Create MySQL" button
  4. Databases are automatically created as demo1, demo2, demo3...
  5. Users and privileges are automatically configured

4. Creating Subdomains

  1. Go to "Subdomains" tab
  2. Enter the number of subdomains to be created
  3. Click "Create Subdomain" button
  4. Subdomains are automatically created as demo1.domain.com, demo2.domain.com...
  5. Document roots and DNS entries are automatically configured

5. Exporting Data

  1. Go to "Export Data" tab
  2. Newly created data appears in preview
  3. Click your desired format button (TXT/CSV/XLSX)
  4. Select file location and save

๐Ÿ“ Project Structure

whm-management-tool/
โ”œโ”€โ”€ main_app.py                    # Main application file
โ”œโ”€โ”€ whm_api.py                     # WHM API operations
โ”œโ”€โ”€ config.py                      # Configuration settings
โ”œโ”€โ”€ requirements.txt               # Python dependencies
โ”œโ”€โ”€ setup.py                       # Package setup (legacy)
โ”œโ”€โ”€ pyproject.toml                 # Modern Python packaging
โ”œโ”€โ”€ README.md                      # Project documentation
โ”œโ”€โ”€ CHANGELOG.md                   # Version history
โ”œโ”€โ”€ CONTRIBUTING.md                # Contribution guidelines
โ”œโ”€โ”€ LICENSE                        # MIT license
โ”œโ”€โ”€ .gitignore                     # Git ignore rules
โ”œโ”€โ”€ .github/                       # GitHub configuration
โ”‚   โ”œโ”€โ”€ workflows/                 # GitHub Actions
โ”‚   โ”‚   โ””โ”€โ”€ ci.yml                # Continuous integration
โ”‚   โ””โ”€โ”€ ISSUE_TEMPLATE/           # Issue templates
โ”‚       โ”œโ”€โ”€ bug_report.md         # Bug report template
โ”‚       โ””โ”€โ”€ feature_request.md    # Feature request template
โ””โ”€โ”€ app_settings.json             # Application settings (auto-generated)

โš™๏ธ Configuration

You can modify basic settings in the config.py file:

APP_CONFIG = {
    'title': 'WHM Management Tool',
    'width': 1400,
    'height': 900
}

# WHM Connection Configuration
CONNECTION_CONFIG = {
    'default_type': 'WHM',  # Connection type: WHM only
    'whm_port': 2087,       # WHM default port
    'ssl': True,            # Use SSL/HTTPS
    'timeout': 30           # Connection timeout in seconds
}

๐Ÿ”ง WHM Connection

WHM Server Management

  • Port: 2087 (HTTPS)

  • Access Level: Server-wide

  • Capabilities:

    • Manage all cPanel accounts
    • Create/delete databases and subdomains for any account
    • Full server administration
  • Typical User: root or reseller with WHM access

๐Ÿ”ง Export Formats

TXT Format

aowsoftware_demo1:aowsoftware_demo1:Abc123!@#:demo1.aowsoftware.com
aowsoftware_demo2:aowsoftware_demo2:Def456$%^:demo2.aowsoftware.com

CSV Format

Database Name,Username,Password,Created Subdomain
aowsoftware_demo1,aowsoftware_demo1,Abc123!@#,demo1.aowsoftware.com
aowsoftware_demo2,aowsoftware_demo2,Def456$%^,demo2.aowsoftware.com

XLSX Format

Excel table with organized columns and automatic width adjustment.

๐Ÿค Contributing

We welcome contributions! Please see our Contributing Guidelines for details.

Quick Start for Contributors

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Make your changes
  4. Run tests (python -m pytest)
  5. Commit your changes (git commit -m 'Add amazing feature')
  6. Push to branch (git push origin feature/amazing-feature)
  7. Open a Pull Request

๐Ÿ› Issues and Support

If you encounter any issues or need support:

  1. Check the Issues to see if your problem has been reported
  2. Create a new issue with detailed information about your problem
  3. Include your system information and error messages
  4. Provide steps to reproduce the issue

๐Ÿ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

๐Ÿ“ˆ Changelog

See CHANGELOG.md for a detailed history of changes.

๐ŸŒŸ Star History

Star History Chart


Made with โค๏ธ for WHM server administrators

smtozkn06/WHM-Management-Tool | GitHunt