jpriddle

/work / TurboHub

TurboHub

A2 Hosting, Inc

Technical Lead / System Architect

Feb 2023 - Apr 2025 ·
Laravel Laravel Zero PHP Vue.js Inertia.js RabbitMQ Redis MySQL WHMCS GitHub Actions Deployer

TurboHub is a distributed WordPress site management platform built for A2 Hosting. It provides customers with a unified control panel to manage every aspect of their WordPress sites — performance optimization, plugin and theme management, staging environments, security monitoring, and health checks — across shared, VPS, and dedicated hosting plans. The system spans three codebases: a Laravel 10 web application (TurboHub Web), a Laravel Zero agent distributed as a compiled PHAR binary to hosting servers (TurboHub Agent), and a suite of WHMCS provisioning modules that tie it all into A2 Hosting’s billing and account infrastructure. I designed the overall system architecture, built early prototypes to validate the approach, and led a team of 12 developers from MVP through production. The platform ultimately serviced over 385,000 WordPress sites for 110,000 customers across 5,000+ servers in four global regions.

My Role

My role was system architecture and team leadership — I designed the system and guided 12 developers through building it, but the day-to-day development was theirs.

Problem Solved

A2 Hosting customers with WordPress sites had no centralized way to manage them. Performance tuning, plugin updates, staging environments, and security monitoring all required direct server access or third-party tools. There was no visibility into site health at scale, and no way to offer managed WordPress features as a product differentiator. TurboHub gave every customer a single control panel for all their WordPress sites, and gave A2 Hosting a platform to deliver managed WordPress services across their entire infrastructure.

System Architecture

TurboHub is a three-component distributed system:

Communication Flow

The web application sends commands to agents through RabbitMQ using a synchronous RPC pattern. Each agent listens on a queue named after its server’s hostname. When a user requests an action (e.g., list plugins, create a staging site), the web application publishes a message to the target server’s queue with a reply-to callback. The agent processes the command — typically by executing WP-CLI operations on the appropriate WordPress installation — and publishes the result back. This design allows the web application to target any specific server among thousands without maintaining persistent connections.

Real-time UI updates are pushed to the browser via Pusher on private, per-user channels, so long-running operations like performance optimization or staging creation provide live progress feedback.

Authentication and Access Control

Authentication flows through WHMCS OAuth. When a customer accesses TurboHub, the web application validates their session against WHMCS and maps their client group membership to an access level: internal (staff), beta (testers), or stable (production customers). This enabled phased feature rollouts during development. Agency support allows users managing multiple client accounts to switch contexts, and admin masquerading supports customer service workflows.

TurboHub Web

The web application is built on Laravel 10 with a Vue 3 frontend powered by Inertia.js, providing a single-page application experience with server-side rendering and no separate API layer.

Core Features

TurboHub Agent

The agent is a Laravel Zero CLI application compiled into a single PHAR binary for distribution. It runs on every hosting server as a pool of Supervisord-managed processes consuming messages from RabbitMQ.

Architecture

The agent uses a configuration-driven routing system. Incoming RabbitMQ messages contain a dot-notation function name (e.g., wordpress.plugins.list) that is resolved through a route configuration map to a specific service class and method. This allows new operations to be added by registering a route and implementing the handler, without modifying the message processing infrastructure.

The agent supports 75+ operations organized across service classes for WordPress core management, plugin and theme operations, performance optimization, staging environments, site discovery, cPanel integration, and server health checks.

WordPress Integration

The agent wraps WP-CLI for all WordPress operations, executing commands as the appropriate cPanel user via sudo with configurable memory limits and timeouts. A plugin blacklist mechanism handles problematic plugins that cause WP-CLI errors — when a plugin error is detected, the agent automatically retries with that plugin skipped, and sends a Slack notification for investigation.

Site discovery uses WP-CLI’s find command to enumerate all WordPress installations under /home/, validating each against cPanel user records and PHP/WordPress version compatibility requirements.

Deployment and Distribution

GitHub Actions builds the PHAR binary on each release and distributes it to four regional package repositories (Arizona, Miami, Netherlands, Singapore). Servers pull updates through an update script managed by the existing configuration management system. Supervisord automatically restarts consumer processes after updates.

Security

The agent authenticates to RabbitMQ using per-server tokens stored outside the application directory. All RabbitMQ connections use TLS 1.2+ with certificate verification. Privilege escalation for WP-CLI and cPanel operations is managed through tightly scoped sudoers rules that restrict the rmq service user to specific binaries and path patterns.

WHMCS Integration

TurboHub integrates with WHMCS through several modules within A2 Hosting’s customized WHMCS installation:

Impact