114 lines
7.3 KiB
PHP
114 lines
7.3 KiB
PHP
<div class="space-y-5">
|
|
{{-- Header --}}
|
|
<div class="flex flex-wrap items-center gap-4 rounded-xl border border-line bg-surface p-5 shadow-panel">
|
|
<span class="grid h-14 w-14 shrink-0 place-items-center rounded-xl border border-accent/25 bg-accent/10 text-accent">
|
|
<x-icon name="settings" class="h-6 w-6" />
|
|
</span>
|
|
<div class="min-w-0 flex-1">
|
|
<p class="font-mono text-[11px] uppercase tracking-[0.2em] text-accent-text">System</p>
|
|
<h2 class="mt-0.5 truncate font-display text-xl font-semibold text-ink">Domain, TLS & Release-Kanal</h2>
|
|
<p class="truncate font-mono text-[11px] text-ink-3">Zugriffsadresse des Panels und Update-Quelle</p>
|
|
</div>
|
|
<span @class([
|
|
'inline-flex items-center gap-1.5 rounded-full border px-2.5 py-1 font-mono text-[11px]',
|
|
'border-online/30 text-online' => $hasTls,
|
|
'border-warning/30 text-warning' => ! $hasTls,
|
|
])>
|
|
<x-status-dot :status="$hasTls ? 'online' : 'warning'" />{{ $hasTls ? 'HTTPS aktiv' : 'Klartext-HTTP' }}
|
|
</span>
|
|
</div>
|
|
|
|
{{-- Domain & TLS --}}
|
|
<x-panel title="Domain & TLS" subtitle="Erreichbarkeit des Panels und Let's-Encrypt-Zertifikat">
|
|
{{-- Current TLS state --}}
|
|
@if ($hasTls)
|
|
<div class="mb-4 flex items-start gap-3 rounded-md border border-online/25 bg-online/5 p-3">
|
|
<x-icon name="shield" class="mt-0.5 h-4 w-4 shrink-0 text-online" />
|
|
<div class="min-w-0">
|
|
<p class="text-sm text-ink">TLS aktiv — Zertifikat automatisch über Let's Encrypt</p>
|
|
<p class="mt-0.5 font-mono text-[11px] text-ink-3">Erreichbar unter
|
|
<a href="{{ $panelUrl }}" class="text-accent-text hover:underline">{{ $panelUrl }}</a> ·
|
|
wird automatisch ausgestellt und erneuert. Voraussetzung: die Domain zeigt per DNS auf diesen Server.</p>
|
|
</div>
|
|
</div>
|
|
@else
|
|
<div class="mb-4 flex items-start gap-3 rounded-md border border-warning/25 bg-warning/5 p-3">
|
|
<x-icon name="alert" class="mt-0.5 h-4 w-4 shrink-0 text-warning" />
|
|
<div class="min-w-0">
|
|
<p class="text-sm text-ink">Bare-IP-Modus: Klartext-HTTP</p>
|
|
<p class="mt-0.5 font-mono text-[11px] text-ink-3">Ohne Domain läuft das Panel inkl. 2FA und Audit über unverschlüsseltes HTTP. Domain eintragen — TLS wird dann automatisch eingerichtet, ohne weitere Schritte.</p>
|
|
</div>
|
|
</div>
|
|
@endif
|
|
|
|
{{-- Architecture rationale: why TLS is terminated by Caddy (collapsible) --}}
|
|
<div class="mb-4 rounded-md border border-line bg-inset p-3" x-data="{ open: false }">
|
|
<button type="button" @click="open = ! open" class="flex w-full items-center gap-2 text-left">
|
|
<x-icon name="shield" class="h-3.5 w-3.5 shrink-0 text-ink-3" />
|
|
<span class="text-sm text-ink-2">Warum läuft TLS über Caddy?</span>
|
|
<span class="ml-auto shrink-0 font-mono text-[10px] uppercase tracking-wider text-ink-4" x-text="open ? 'schließen' : 'mehr'"></span>
|
|
</button>
|
|
<div x-show="open" x-cloak x-transition class="mt-2.5 space-y-1.5 font-mono text-[11px] leading-relaxed text-ink-3">
|
|
<p>Clusev nutzt <span class="text-ink-2">genau einen</span> nach außen offenen Dienst: Caddy. Es terminiert TLS, holt und erneuert das Let's-Encrypt-Zertifikat automatisch und leitet die Reverb-WebSockets (wss) über dieselbe Adresse — ohne Skript, Cronjob oder Reload-Hook.</p>
|
|
<p>App und Reverb bleiben intern erreichbar (kein offener Port nach außen). Caddy ist ein eigener Container mit eigener Version, daher kann ein App-Update die TLS-Terminierung nie unterbrechen.</p>
|
|
<p>Ein zusätzliches certbot + nginx wären <span class="text-ink-2">mehr</span> bewegliche Teile (eigene 443-Konfiguration, WebSocket-Upgrade, Renewal-Timer, Reload-Hook) — bei nur einer Domain kein Gewinn.</p>
|
|
</div>
|
|
</div>
|
|
|
|
{{-- Read-only: the panel domain is an install-time decision (kept consistent
|
|
with URL/WebSocket/cookie security); TLS provisions itself automatically. --}}
|
|
<dl class="divide-y divide-line overflow-hidden rounded-md border border-line">
|
|
<div class="flex items-center justify-between gap-3 px-4 py-2.5">
|
|
<dt class="text-sm text-ink-2">Domain</dt>
|
|
<dd class="truncate font-mono text-sm text-ink">{{ $domain !== '' ? $domain : '— (Zugriff per IP)' }}</dd>
|
|
</div>
|
|
<div class="flex items-center justify-between gap-3 px-4 py-2.5">
|
|
<dt class="text-sm text-ink-2">Zugriffsadresse</dt>
|
|
<dd class="truncate font-mono text-sm text-ink">
|
|
@if ($panelUrl)
|
|
<a href="{{ $panelUrl }}" class="text-accent-text hover:underline">{{ $panelUrl }}</a>
|
|
@else
|
|
HTTP (Bare-IP)
|
|
@endif
|
|
</dd>
|
|
</div>
|
|
</dl>
|
|
<p class="mt-2.5 font-mono text-[11px] leading-relaxed text-ink-4">
|
|
Die Panel-Domain wird bei der Installation gesetzt und bleibt mit URL, WebSocket und
|
|
Cookie-Sicherheit konsistent. Zum Ändern <span class="text-ink-3">install.sh</span> mit der
|
|
neuen Domain erneut ausführen — TLS richtet sich danach automatisch ein.
|
|
</p>
|
|
</x-panel>
|
|
|
|
{{-- Release-Kanal --}}
|
|
<x-panel title="Release-Kanal" subtitle="Quelle für Updates">
|
|
<div class="space-y-4">
|
|
{{-- Segmented control --}}
|
|
<div role="radiogroup" aria-label="Release-Kanal" class="inline-flex w-full max-w-md rounded-md border border-line bg-inset p-1">
|
|
@foreach ($channels as $key => $desc)
|
|
<button type="button"
|
|
role="radio"
|
|
aria-checked="{{ $channel === $key ? 'true' : 'false' }}"
|
|
wire:click="confirmChannel('{{ $key }}')"
|
|
@class([
|
|
'inline-flex h-9 flex-1 items-center justify-center gap-1.5 rounded font-mono text-xs uppercase tracking-wider transition-colors',
|
|
'bg-accent/15 text-accent-text shadow-[inset_0_0_0_1px_var(--color-accent)]' => $channel === $key,
|
|
'text-ink-3 hover:bg-raised hover:text-ink-2' => $channel !== $key,
|
|
])>
|
|
@if ($channel === $key)<x-icon name="git-branch" class="h-3.5 w-3.5" />@endif{{ $key }}
|
|
</button>
|
|
@endforeach
|
|
</div>
|
|
|
|
{{-- Per-channel description --}}
|
|
<div class="flex items-start gap-3 rounded-md border border-line bg-raised/40 p-3">
|
|
<x-icon name="git-branch" class="mt-0.5 h-4 w-4 shrink-0 text-accent-text" />
|
|
<div class="min-w-0">
|
|
<p class="text-sm text-ink">Kanal: <span class="font-mono text-accent-text">{{ $channel }}</span></p>
|
|
<p class="mt-0.5 font-mono text-[11px] text-ink-3">{{ $channels[$channel] ?? '' }}</p>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</x-panel>
|
|
</div>
|