feat: bootstrap webspace deploy and status-beacon landing page

Add public/index.php, private config bootstrap, FTPS deploy script,
and complete todo/01 including Let's Encrypt, HTTPS redirect, and HSTS docs.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Frank Schwenk
2026-06-11 22:37:06 +02:00
parent 54d29d3afa
commit 659154c93a
9 changed files with 335 additions and 18 deletions
+80
View File
@@ -0,0 +1,80 @@
<?php
declare(strict_types=1);
require_once dirname(__DIR__) . '/private/config/bootstrap.php';
$domain = env('DOMAIN', '0012.de');
$bokaIp = env('BOKA_IP', '89.163.231.180');
$checksFile = privateDataDir() . '/last-checks.json';
$checks = is_readable($checksFile)
? json_decode((string) file_get_contents($checksFile), true)
: null;
$lastRun = is_array($checks) && isset($checks['updated_at'])
? $checks['updated_at']
: null;
header('Content-Type: text/html; charset=utf-8');
header('X-Robots-Tag: noindex');
?>
<!DOCTYPE html>
<html lang="de">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title><?= htmlspecialchars($domain, ENT_QUOTES, 'UTF-8') ?> · external observer</title>
<style>
:root {
--bg: #0d1117;
--text: #c9d1d9;
--muted: #8b949e;
--accent: #58a6ff;
--warn: #d29922;
--ok: #3fb950;
}
* { box-sizing: border-box; }
body {
margin: 0;
min-height: 100vh;
background: var(--bg);
color: var(--text);
font-family: ui-monospace, "Cascadia Code", "JetBrains Mono", monospace;
line-height: 1.5;
padding: 2rem 1.25rem 3rem;
}
main { max-width: 42rem; margin: 0 auto; }
h1 { font-size: 1.25rem; font-weight: 600; margin: 0 0 0.25rem; letter-spacing: 0.04em; }
.tagline { color: var(--muted); margin: 0 0 2rem; font-size: 0.9rem; }
.panel {
border: 1px solid #30363d;
border-radius: 8px;
padding: 1.25rem 1.5rem;
background: #161b22;
}
.status { color: var(--warn); margin: 0 0 0.75rem; }
.status.ok { color: var(--ok); }
.meta { color: var(--muted); font-size: 0.85rem; margin: 1.5rem 0 0; }
code { color: var(--accent); }
</style>
</head>
<body>
<main>
<h1>0012</h1>
<p class="tagline">external observer node · watching from outside</p>
<div class="panel">
<?php if ($lastRun): ?>
<p class="status ok">Monitoring active — last check <?= htmlspecialchars($lastRun, ENT_QUOTES, 'UTF-8') ?></p>
<?php else: ?>
<p class="status">Monitoring not initialized — awaiting first cron run</p>
<?php endif; ?>
<p class="meta">
Node <code><?= htmlspecialchars($domain, ENT_QUOTES, 'UTF-8') ?></code>
· independent of boka (<code><?= htmlspecialchars($bokaIp, ENT_QUOTES, 'UTF-8') ?></code>)
</p>
</div>
</main>
</body>
</html>