Files
KeruOS/web/live-init.html
T

65 lines
3.6 KiB
HTML

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Live init — Keru OS docs</title>
<meta name="description" content="The live/init reference: how booting the Keru ISO auto-starts the installer.">
<link rel="stylesheet" href="assets/css/style.css">
<link rel="icon" href="data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'><text y='.9em' font-size='90'>ける</text></svg>">
</head>
<body>
<nav class="top" data-nav></nav>
<header class="pagehead">
<p class="crumbs"><a href="index.html">home</a> / <a href="docs.html">docs</a> / live init</p>
<h1>Live init</h1>
<p>Boot the ISO, and the installer starts itself.</p>
</header>
<section>
<div class="wrap">
<div class="prose">
<p><code>live/init</code> is the init for the Keru live ISO. Its entire job is to get you into the installer as fast as possible — no shell prompt, no manual steps between boot and "craft your system."</p>
<h3>What it does, in order</h3>
<ol>
<li><strong>Sets up the console.</strong> Redirects to <code>$CONSOLE</code> (<code>/dev/tty1</code> by default) so installer messages land where you can see them.</li>
<li><strong>Mounts virtual filesystems.</strong> <code>/proc</code>, <code>/sys</code>, <code>/dev</code> (devtmpfs, with tmpfs fallback), <code>/dev/pts</code>, <code>/dev/shm</code> — the essentials the installer needs.</li>
<li><strong>Locates the installer root.</strong> Uses the kernel's <code>root=</code> if given, or looks for a <code>KERU*</code>-labeled device to find the read-only squashfs payload; otherwise assumes the installer is on the current root.</li>
<li><strong>Execs the installer.</strong> <code>exec sh installer/install.sh</code> — the TUI starts immediately.</li>
<li><strong>Emergency shell fallback.</strong> If the installer exited or isn't found, you get an interactive rescue shell instead of a hang.</li>
</ol>
<div class="terminal">
<div class="tbar"><span class="dot r"></span><span class="dot y"></span><span class="dot g"></span><span class="t">live/init</span></div>
<pre>[ keru ] booting installer...
<span class="c">[ keru ] Keru OS — craft your system</span>
== Init system == [runit]
== C library == [glibc]
== Filesystem == [ext4]
<span class="p"># and you're choosing — the installer opened itself.</span></pre>
</div>
<h3>Design notes</h3>
<ul class="features">
<li><strong>Ultra-minimal.</strong> The live env is busybox + the installer. No init system in the live env — this script <em>is</em> the init.</li>
<li><strong>Never strand you.</strong> The emergency shell is deliberate: "installer not found or exited" should never be a dead end.</li>
<li><strong>Console-aware.</strong> It listens to the <code>console=</code> kernel param so serial consoles work too.</li>
</ul>
<div class="callout">This is the "boot → choose → it builds" promise made real: the ISO carries the installer, and live/init hands it straight to you.</div>
<p><a href="installer-walkthrough.html">What happens after it starts</a> · <a href="docs.html">← Docs</a></p>
</div>
</div>
</section>
<footer data-footer></footer>
<noscript><div style="text-align:center;padding:16px">See the <a href="sitemap.html">sitemap</a> for all pages.</div></noscript>
<script src="assets/js/include.js" data-base="."></script>
</body>
</html>