From f064cc89bafe817b8e9cd8334d224b9df31a5276 Mon Sep 17 00:00:00 2001 From: MacRimi Date: Fri, 7 Nov 2025 20:55:00 +0100 Subject: [PATCH] Update AppImage --- AppImage/components/hardware.tsx | 2 +- AppImage/components/network-metrics.tsx | 6 +++--- AppImage/components/proxmox-dashboard.tsx | 5 ++--- AppImage/components/system-overview.tsx | 8 ++++---- AppImage/components/two-factor-setup.tsx | 2 +- AppImage/components/virtual-machines.tsx | 5 ++--- AppImage/scripts/build_appimage.sh | 2 ++ 7 files changed, 15 insertions(+), 15 deletions(-) diff --git a/AppImage/components/hardware.tsx b/AppImage/components/hardware.tsx index 6ff29b6..15db5a0 100644 --- a/AppImage/components/hardware.tsx +++ b/AppImage/components/hardware.tsx @@ -180,7 +180,7 @@ export default function Hardware() { error: dynamicError, isLoading: dynamicLoading, } = useSWR("/api/hardware", fetcher, { - refreshInterval: 5000, // 5 second refresh for dynamic data + refreshInterval: 7000, }) // Merge static and dynamic data, preferring static for CPU/memory/PCI/disks diff --git a/AppImage/components/network-metrics.tsx b/AppImage/components/network-metrics.tsx index ae8a59f..6b6de14 100644 --- a/AppImage/components/network-metrics.tsx +++ b/AppImage/components/network-metrics.tsx @@ -149,7 +149,7 @@ export function NetworkMetrics() { error, isLoading, } = useSWR("/api/network", fetcher, { - refreshInterval: 60000, // Refresh every 60 seconds + refreshInterval: 53000, revalidateOnFocus: false, revalidateOnReconnect: true, }) @@ -161,13 +161,13 @@ export function NetworkMetrics() { const [interfaceTotals, setInterfaceTotals] = useState<{ received: number; sent: number }>({ received: 0, sent: 0 }) const { data: modalNetworkData } = useSWR(selectedInterface ? "/api/network" : null, fetcher, { - refreshInterval: 15000, // Refresh every 15 seconds when modal is open + refreshInterval: 17000, revalidateOnFocus: false, revalidateOnReconnect: true, }) const { data: interfaceHistoricalData } = useSWR(`/api/node/metrics?timeframe=${timeframe}`, fetcher, { - refreshInterval: 30000, + refreshInterval: 29000, revalidateOnFocus: false, }) diff --git a/AppImage/components/proxmox-dashboard.tsx b/AppImage/components/proxmox-dashboard.tsx index 9cce96a..199e1c6 100644 --- a/AppImage/components/proxmox-dashboard.tsx +++ b/AppImage/components/proxmox-dashboard.tsx @@ -123,12 +123,11 @@ export function ProxmoxDashboard() { // Siempre fetch inicial fetchSystemData() - // Solo hacer polling si estamos en overview let interval: ReturnType | null = null if (activeTab === "overview") { - interval = setInterval(fetchSystemData, 10000) + interval = setInterval(fetchSystemData, 9000) // Cambiado de 10000 a 9000ms } else { - interval = setInterval(fetchSystemData, 60000) + interval = setInterval(fetchSystemData, 61000) // Cambiado de 60000 a 61000ms } return () => { diff --git a/AppImage/components/system-overview.tsx b/AppImage/components/system-overview.tsx index 20204f4..9c41550 100644 --- a/AppImage/components/system-overview.tsx +++ b/AppImage/components/system-overview.tsx @@ -259,7 +259,7 @@ export function SystemOverview() { fetchSystemData().then((data) => { if (data) setSystemData(data) }) - }, 10000) + }, 9000) // Cambiado de 10000 a 9000ms return () => { clearInterval(systemInterval) @@ -273,7 +273,7 @@ export function SystemOverview() { } fetchVMs() - const vmInterval = setInterval(fetchVMs, 60000) + const vmInterval = setInterval(fetchVMs, 59000) // Cambiado de 60000 a 59000ms return () => { clearInterval(vmInterval) @@ -290,7 +290,7 @@ export function SystemOverview() { } fetchStorage() - const storageInterval = setInterval(fetchStorage, 60000) + const storageInterval = setInterval(fetchStorage, 59000) // Cambiado de 60000 a 59000ms return () => { clearInterval(storageInterval) @@ -304,7 +304,7 @@ export function SystemOverview() { } fetchNetwork() - const networkInterval = setInterval(fetchNetwork, 60000) + const networkInterval = setInterval(fetchNetwork, 59000) // Cambiado de 60000 a 59000ms return () => { clearInterval(networkInterval) diff --git a/AppImage/components/two-factor-setup.tsx b/AppImage/components/two-factor-setup.tsx index e20f1c8..f62598a 100644 --- a/AppImage/components/two-factor-setup.tsx +++ b/AppImage/components/two-factor-setup.tsx @@ -197,7 +197,7 @@ export function TwoFactorSetup({ open, onClose, onSuccess }: TwoFactorSetupProps placeholder="000000" value={verificationCode} onChange={(e) => setVerificationCode(e.target.value.replace(/\D/g, "").slice(0, 6))} - className="text-center text-lg tracking-widest font-mono" + className="text-center text-lg tracking-widest font-mono text-base" maxLength={6} disabled={loading} /> diff --git a/AppImage/components/virtual-machines.tsx b/AppImage/components/virtual-machines.tsx index 5d82ec5..dd0ffcb 100644 --- a/AppImage/components/virtual-machines.tsx +++ b/AppImage/components/virtual-machines.tsx @@ -264,7 +264,7 @@ export function VirtualMachines() { isLoading, mutate, } = useSWR("/api/vms", fetcher, { - refreshInterval: 30000, + refreshInterval: 23000, revalidateOnFocus: false, revalidateOnReconnect: true, }) @@ -451,7 +451,7 @@ export function VirtualMachines() { "/api/system", fetcher, { - refreshInterval: 30000, + refreshInterval: 23000, revalidateOnFocus: false, }, ) @@ -1102,7 +1102,6 @@ export function VirtualMachines() { View and manage configuration, resources, and status for this virtual machine - {/* */}
diff --git a/AppImage/scripts/build_appimage.sh b/AppImage/scripts/build_appimage.sh index f43b901..5024f76 100644 --- a/AppImage/scripts/build_appimage.sh +++ b/AppImage/scripts/build_appimage.sh @@ -284,6 +284,8 @@ pip3 install --target "$APP_DIR/usr/lib/python3/dist-packages" \ psutil \ requests \ PyJWT \ + pyotp \ + qrcode[pil] \ googletrans==4.0.0-rc1 \ httpx==0.13.3 \ httpcore==0.9.1 \