#!/usr/bin/env -S node --experimental-strip-types /** * The lab's two callers want different things from the same verbs: a coordinator wants * structured results and clean teardown, a person wants readable output and the failing * scenario left standing. Both use these verbs; the difference is what happens after. */ import { loadScenario } from "./declaration/parse.ts"; import { DeclarationError } from "./declaration/validate.ts"; import { isReachable, supportedDrivers, pools } from "./incus/client.ts"; import { raise, RaiseError } from "./lifecycle/raise.ts"; import { assertSupported, UnsupportedError } from "./lifecycle/supported.ts"; import { diagramFromDeclaration } from "./diagram/from-declaration.ts"; import { diagramFromLive } from "./diagram/from-live.ts"; import { toDrawio } from "./diagram/drawio.ts"; import { writeFileSync } from "node:fs"; import { destroy, exec, list, restore, snapshot, snapshots } from "./lifecycle/operate.ts"; const USAGE = `mesh-lab — raise a disposable mesh on one machine check verify this machine can run scenarios validate parse and check a declaration, raising nothing raise materialise it, and wait until the machines are usable list scenario instances currently standing exec -- snapshot