query($sql);
if ($stmt) {
while ($row = $stmt->fetch(PDO::FETCH_ASSOC)) {
$servers[] = [
'id' => (int)$row['id'],
'name' => $row['name'],
'panel_url' => $row['panel_url'],
'provider' => $row['provider'] ?? '',
'ip' => $row['ip_address'] ?? '',
'ip_address' => $row['ip_address'] ?? '',
'username' => $row['username'] ?? '',
'api_enabled' => (int)$row['api_enabled'],
'api_status' => ((int)$row['api_enabled'] === 1) ? 'enabled' : 'disabled',
'environment' => $row['environment'] ?? 'production',
'notes' => $row['notes'] ?? '',
'status' => $row['last_status'] ?: 'warning',
'cpu' => 0,
'ram' => 0,
'disk' => 0,
'websites' => 0,
'databases' => 0,
'ssl_expiring' => 0,
'last_check' => $row['last_check'] ?: '-'
];
}
}
$packagesByServer = [];
$stmtPackages = $db->query("
SELECT
id,
server_id,
package_name,
disk_space,
bandwidth,
email_accounts,
ftp_accounts,
databases_count,
domains_count,
last_sync
FROM cyberpanel_packages
ORDER BY package_name ASC
");
if ($stmtPackages) {
while ($package = $stmtPackages->fetch(PDO::FETCH_ASSOC)) {
$serverId = (int)$package['server_id'];
if (!isset($packagesByServer[$serverId])) {
$packagesByServer[$serverId] = [];
}
$packagesByServer[$serverId][] = $package;
}
}
$domains = [
[
'domain' => 'yogasoul.it',
'server' => 'OVH VPS 1',
'php' => '8.2',
'ssl' => 'Valid',
'disk' => '4.8 GB',
'status' => 'Online',
'panel_url' => 'https://server1.claudiosironi.com:8090'
],
[
'domain' => 'claudiosironi.com',
'server' => 'OVH VPS 1',
'php' => '8.1',
'ssl' => 'Valid',
'disk' => '2.1 GB',
'status' => 'Online',
'panel_url' => 'https://server1.claudiosironi.com:8090'
],
[
'domain' => 'villadonatella.com',
'server' => 'Client VPS Keliweb',
'php' => '8.2',
'ssl' => 'Expiring',
'disk' => '8.7 GB',
'status' => 'Warning',
'panel_url' => 'https://panel-client.example.com:8090'
],
[
'domain' => 'test-app.local',
'server' => 'Test Server',
'php' => '8.3',
'ssl' => 'Missing',
'disk' => '1.2 GB',
'status' => 'Offline',
'panel_url' => 'https://test-server.example.com:8090'
]
];
$totalServers = count($servers);
$onlineServers = count(array_filter($servers, fn($s) => $s['status'] === 'online'));
$warningServers = count(array_filter($servers, fn($s) => $s['status'] === 'warning'));
$offlineServers = count(array_filter($servers, fn($s) => $s['status'] === 'offline'));
$totalWebsites = array_sum(array_column($servers, 'websites'));
$totalDatabases = array_sum(array_column($servers, 'databases'));
$totalSslExpiring = array_sum(array_column($servers, 'ssl_expiring'));
?>
Total Servers
= (int)$totalServers; ?>
Online Servers
= (int)$onlineServers; ?>
Websites
= (int)$totalWebsites; ?>
SSL Expiring
= (int)$totalSslExpiring; ?>
Servers
Domains / Websites
CyberPanel Controls
Logs
= htmlspecialchars($server['name'], ENT_QUOTES, 'UTF-8'); ?>
= htmlspecialchars($server['panel_url'], ENT_QUOTES, 'UTF-8'); ?>
= htmlspecialchars(ucfirst($server['status']), ENT_QUOTES, 'UTF-8'); ?>
Provider
= htmlspecialchars($server['provider'] ?: '-', ENT_QUOTES, 'UTF-8'); ?>
IP
= htmlspecialchars($server['ip_address'] ?: '-', ENT_QUOTES, 'UTF-8'); ?>
Env
= htmlspecialchars(ucfirst($server['environment'] ?? 'production'), ENT_QUOTES, 'UTF-8'); ?>
CPU
= (int)$server['cpu']; ?>%
RAM
= (int)$server['ram']; ?>%
Disk
= (int)$server['disk']; ?>%
Websites
= (int)$server['websites']; ?>
Databases
= (int)$server['databases']; ?>
API
= htmlspecialchars(ucfirst($server['api_status']), ENT_QUOTES, 'UTF-8'); ?>
Last check:
= htmlspecialchars($server['last_check'], ENT_QUOTES, 'UTF-8'); ?>
Domains / Websites
Theoretical list of websites detected from all CyberPanel servers.
Create Website
Domain
Server
PHP
SSL
Disk
Status
Actions
= htmlspecialchars($domain['domain'], ENT_QUOTES, 'UTF-8'); ?>
= htmlspecialchars($domain['server'], ENT_QUOTES, 'UTF-8'); ?>
PHP = htmlspecialchars($domain['php'], ENT_QUOTES, 'UTF-8'); ?>
= htmlspecialchars($domain['ssl'], ENT_QUOTES, 'UTF-8'); ?>
= htmlspecialchars($domain['disk'], ENT_QUOTES, 'UTF-8'); ?>
= htmlspecialchars($domain['status'], ENT_QUOTES, 'UTF-8'); ?>
Verify Connection
Test API credentials and check if the CyberPanel instance is reachable.
Run Check
List Websites
Retrieve all websites configured on the selected CyberPanel server.
Load Websites
List Databases
Retrieve databases and database users created in CyberPanel.
Load Databases
SSL Status
Check SSL status and detect domains with certificates close to expiration.
Check SSL
Create Website
Create a new website on the selected CyberPanel server.
Create Website
Backup Website
Launch a backup operation for a selected website or database.
Start Backup
Email Accounts
Read or manage email accounts configured on a specific domain.
Manage Email
Raw API Call
Send a manual API command for debugging and advanced operations.
Open Console
API Logs
Temporary theoretical log area. Later it will read from a database table or log files.
Clear View
[2026-05-20 09:42:11] INFO Checking API connection: OVH VPS 1
[2026-05-20 09:42:12] OK verifyConn returned success
[2026-05-20 09:42:14] INFO Loading websites from CyberPanel
[2026-05-20 09:42:15] OK 8 websites detected
[2026-05-20 09:42:20] WARN villadonatella.com SSL will expire soon
[2026-05-20 09:43:02] ERROR Test Server API disabled or unreachable