feat: POSIX/P2P roadmap — proc surfaces, syscalls, boot perf, docs, CI

- Align posix-conformance-matrix bareOsSyscallOps with getconf BARE_OS_SYSCALL_OPS
- Add verify-boot-policy-extension-signer-pins.mjs to pretest; document in scripts/README
- Document extensionSignerPinsV2–V5 env wiring in OTA_AND_BUNDLES; vault multisig sketch
- Note telemetry NDJSON redaction limits in environment appendix
- Expand booter CHANGELOG 1.40.0 (boot-perf, shell POSIX mode, subprocess errors, etc.)
- Holepunch sync README: NDJSON summary path

Seeder/kernel parity and pretest already green for bundled changes.
This commit is contained in:
Raven Scott
2026-04-05 00:02:23 -04:00
parent 16ac71815f
commit 1faf9715b7
67 changed files with 2645 additions and 577 deletions
+55 -1
View File
@@ -34,6 +34,7 @@
* BARE_OS_SELFTEST_FORMAT=tap: TAP-style lines on stderr for CI parsers; **junit**: single XML `<testsuite>` line on stderr.
* BARE_OS_KERNEL_STARTUP_CLASS: `critical` | `system` | `interactive` | `deferred` (default **interactive**); exposed as **`ctx.bareOsKernelStartupClass`** for extensions/initd.
* BARE_OS_BOOT_BUDGET_MS_COLD: optional cold-boot wall-time warning threshold (ms) after **`bareOsPublishBootReady`**.
* BARE_OS_BOOT_BUDGET_MS_BARE_STDLIB: optional wall-time budget (ms) for booter **`ctx.bare`** drive merge + host resolve (**`BARE_OS_BOOT_BARE_STDLIB_RESOLUTION_MS`**, set by the stock booter); guest logs and **`boot-perf.json`** when exceeded.
* BARE_OS_BOOT_CAPABILITY_CONTRACT_DEBUG=1: log capability-contract merge diagnostics (strict builds).
* BARE_OS_BOOT_EXT_RESOLUTION_TRACE=1 with **BARE_OS_BOOT_POLICY_STRICT**: write **`/run/bare-os/kernel-ext-resolution.json`** (extension load order / cycle ids).
* BARE_OS_BOOT_RC_RESOLUTION_TRACE=1 with **BARE_OS_BOOT_POLICY_STRICT**: write **`/run/bare-os/rc-d-resolution.json`** and **`/run/bare-os/kernel-d-resolution.json`** (lexicographic execution order after filters).
@@ -3010,13 +3011,29 @@ async function maybeWriteBootPerfJson(ctx, bootT0, stageLog) {
10
)
const budget = Number.isFinite(budgetRaw) && budgetRaw > 0 ? budgetRaw : null
const stdlibWallRaw = Number.parseInt(
String(ctx.env?.BARE_OS_BOOT_BARE_STDLIB_RESOLUTION_MS || ''),
10
)
const stdlibWall =
Number.isFinite(stdlibWallRaw) && stdlibWallRaw >= 0 ? stdlibWallRaw : null
const stdlibBudgetRaw = Number.parseInt(
String(ctx.env?.BARE_OS_BOOT_BUDGET_MS_BARE_STDLIB || ''),
10
)
const stdlibBudget =
Number.isFinite(stdlibBudgetRaw) && stdlibBudgetRaw > 0
? stdlibBudgetRaw
: null
const stages =
Array.isArray(ctx.bareOsBootStageTimings) && ctx.bareOsBootStageTimings.length
? ctx.bareOsBootStageTimings
: undefined
let schema = stages ? 2 : 1
if (stdlibWall != null || stdlibBudget != null) schema = Math.max(schema, 3)
const row =
JSON.stringify({
schema: stages ? 2 : 1,
schema,
coldWallMs: wall,
bootBudgetMsCold: budget,
withinBudget: budget == null ? null : wall <= budget,
@@ -3024,6 +3041,18 @@ async function maybeWriteBootPerfJson(ctx, bootT0, stageLog) {
budget != null && wall > budget
? `cold boot ${wall}ms exceeded BARE_OS_BOOT_BUDGET_MS_COLD ${budget}ms`
: null,
bareStdlibResolutionWallMs: stdlibWall,
bareStdlibBudgetMs: stdlibBudget,
bareStdlibWithinBudget:
stdlibBudget == null || stdlibWall == null
? null
: stdlibWall <= stdlibBudget,
bareStdlibBudgetWarning:
stdlibBudget != null &&
stdlibWall != null &&
stdlibWall > stdlibBudget
? `bare stdlib resolution ${stdlibWall}ms exceeded BARE_OS_BOOT_BUDGET_MS_BARE_STDLIB ${stdlibBudget}ms`
: null,
stageCount: stageLog.length,
stages,
completedAtMs: Date.now()
@@ -3360,6 +3389,31 @@ async function start(ctx) {
}
}
}
{
const sb = Number.parseInt(
String(ctx.env?.BARE_OS_BOOT_BUDGET_MS_BARE_STDLIB || ''),
10
)
if (Number.isFinite(sb) && sb > 0) {
const sw = Number.parseInt(
String(ctx.env?.BARE_OS_BOOT_BARE_STDLIB_RESOLUTION_MS || ''),
10
)
if (Number.isFinite(sw) && sw > sb) {
bootStructuredLog(
ctx,
'error',
'bootBudgetBareStdlibExceeded',
`[boot] bare stdlib resolution ${sw}ms exceeds BARE_OS_BOOT_BUDGET_MS_BARE_STDLIB=${sb}ms`
)
if (ctx.env) {
ctx.env.BARE_OS_BOOT_BUDGET_STDLIB_EXCEEDED = '1'
ctx.env.BARE_OS_BOOT_BUDGET_STDLIB_WALL_MS = String(sw)
ctx.env.BARE_OS_BOOT_BUDGET_STDLIB_LIMIT_MS = String(sb)
}
}
}
}
while (true) {
const line = await readLine('')
if (line == null) break