@php // Threshold tone for gauges/bars: >=90 offline, >=75 warning, else online. $tone = fn (int $v): string => $v >= 90 ? 'offline' : ($v >= 75 ? 'warning' : 'online'); $barColor = ['online' => 'bg-online', 'warning' => 'bg-warning', 'offline' => 'bg-offline']; $statusLabel = ['online' => 'Online', 'warning' => 'Warnung', 'offline' => 'Offline'][$server->status] ?? ucfirst($server->status); $specs = $server->specs ?? []; $cores = $specs['cores'] ?? null; $ramGb = $specs['ram_gb'] ?? null; $diskGb = $specs['disk_gb'] ?? null; $ramUsed = $ramGb !== null ? round((float) $ramGb * $server->mem / 100, 1) : null; $diskUsed = $diskGb !== null ? (int) round((float) $diskGb * $server->disk / 100) : null; $specRows = [ ['Architektur', $specs['arch'] ?? '—'], ['Kernel', $specs['kernel'] ?? '—'], ['Virtualisierung', $specs['virt'] ?? '—'], ['Kerne', $cores ?? '—'], ['RAM', $ramGb !== null ? $ramGb.' GB' : '—'], ['Disk', $diskGb !== null ? $diskGb.' GB' : '—'], ]; $vitals = [ ['label' => 'CPU', 'icon' => 'cpu', 'val' => (int) $server->cpu, 'sub' => ($loadAvg > 0 ? 'Last '.number_format($loadAvg, 2).' · ' : '').($cores ? $cores.' Kerne' : '—')], ['label' => 'RAM', 'icon' => 'activity', 'val' => (int) $server->mem, 'sub' => $ramUsed !== null ? $ramUsed.' / '.$ramGb.' GB' : '—'], ['label' => 'Disk', 'icon' => 'server', 'val' => (int) $server->disk, 'sub' => $diskUsed !== null ? $diskUsed.' / '.$diskGb.' GB' : '—'], ]; @endphp
Zurück zur Flotte {{-- Hero header --}}
$server->status === 'online', 'border-warning/30 bg-warning/10 text-warning' => $server->status === 'warning', 'border-offline/30 bg-offline/10 text-offline' => $server->status === 'offline', ])>

{{ $server->name }}

{{ $statusLabel }}

{{ $server->hostname }} · {{ $server->ip }} · {{ $server->os }} · Uptime {{ $server->uptime ?: '—' }} · zuletzt {{ optional($server->last_seen_at)->diffForHumans() ?? '—' }}

Zugang Dateien
@if ($ready && ! $connected)

Keine Live-Verbindung — gezeigt werden die zuletzt gespeicherten Werte. Zugang/Erreichbarkeit prüfen.

@endif {{-- Vitals: live gauges, full width, dense --}}
@foreach ($vitals as $v)

{{ $v['label'] }}

{{ $v['sub'] }}

@endforeach
@if ($ready) {{-- Spezifikationen + Sicherheit --}}
@foreach ($specRows as [$key, $val])
{{ $key }}
{{ $val }}
@endforeach
@foreach ($hardening as $check)
$check['status'] === 'online', 'border-warning' => $check['status'] === 'warning', 'border-offline' => $check['status'] === 'offline', ])>

{{ $check['label'] }}

{{ $check['detail'] }}

{{ $check['status'] === 'online' ? 'OK' : 'Fehlt' }}
@endforeach
{{-- Volumes + Netzwerk-Interfaces --}}
@forelse ($volumes as $vol) @php $vt = $tone((int) $vol['used']); @endphp

{{ $vol['mount'] }}

{{ $vol['fs'] }} · {{ $vol['size'] }}

{{ $vol['used'] }}%
@empty

Keine Volumes gelesen.

@endforelse
@foreach ($interfaces as $if) @endforeach
Name IP MAC RX TX
{{ $if['name'] }} {{ $if['ip'] }} {{ $if['mac'] }} {{ $if['rx'] }} {{ $if['tx'] }}
{{-- SSH-Schlüssel --}} Schlüssel hinzufügen
@forelse ($sshKeys as $key)

{{ $key['comment'] }}

{{ $key['type'] }}

{{ $key['fingerprint'] }}

@empty

Keine autorisierten Schlüssel.

@endforelse
@else {{-- skeletons for the SSH-loaded sections --}}
@foreach (['Spezifikationen', 'Sicherheit'] as $t)
@endforeach
@foreach (['Volumes', 'Netzwerk-Interfaces'] as $t)
@endforeach
@endif