commit d1fb5db734e3d7a42acffb23ef7ab6e6a754974d Author: iv3scp Date: Tue Apr 21 00:11:59 2026 +0200 Upload files to "/" diff --git a/api.php b/api.php new file mode 100644 index 0000000..27436fc --- /dev/null +++ b/api.php @@ -0,0 +1,57 @@ + $node['vmid'], 'name' => $node['name'], 'status' => $node['status'], 'type' => 'qemu', + 'ip' => !empty($ips) ? implode(", ", array_unique($ips)) : "N/D", + 'cpu' => $node['cpu'], 'mem' => $node['mem'], 'maxmem' => $node['maxmem'], + 'disk' => $node['disk'], 'maxdisk' => $node['maxdisk'], + 'netin' => $node['netin'], 'netout' => $node['netout'] + ]; +} + +foreach ($lxc as $node) { + $ip = "N/D"; + if (!empty($node['tags']) && preg_match('/(\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3})/', $node['tags'], $matches)) $ip = $matches[1]; + $results[] = [ + 'vmid' => $node['vmid'], 'name' => $node['name'], 'status' => $node['status'], 'type' => 'lxc', 'ip' => $ip, + 'cpu' => $node['cpu'], 'mem' => $node['mem'], 'maxmem' => $node['maxmem'], + 'disk' => $node['disk'], 'maxdisk' => $node['maxdisk'], + 'netin' => $node['netin'], 'netout' => $node['netout'] + ]; +} + +echo json_encode($results); +?> \ No newline at end of file diff --git a/config.ini b/config.ini new file mode 100644 index 0000000..90f3ec6 --- /dev/null +++ b/config.ini @@ -0,0 +1,7 @@ +[proxmox] +host = "IP_Proxmox" +node = "Name_Node" +user = "root@pam" +token_name = "dashboard" +token_value = "SEGRET" +port = 8006 diff --git a/index.html b/index.html new file mode 100644 index 0000000..23e0101 --- /dev/null +++ b/index.html @@ -0,0 +1,118 @@ + + + + + Proxmox Pro Dashboard + + + + + +
+
+
+
+

Proxmox Pro Dashboard

+

Live Node Stats

+
+
+
Inizializzazione...
+
+ +
+ + + +