/** * Recipe runner — orchestrates execution across hosts. * * Creates an ExecutionContext per host, loads and executes the recipe function, * and produces a RunSummary with per-host results and timing. Manages transport * lifecycle (close/cleanup) per host. Supports bounded host-level concurrency * with cancellation and timeout semantics. Optionally emits lifecycle events * via an EventBus for observability. */ import type { CheckResultCache, ConcurrencyOptions, ErrorMode, HostContext, Reporter, ResourcePolicy, RunMode, RunSummary } from "./types.ts"; import type { Transport } from "../ssh/types.ts"; import type { RecipeFunction } from "../recipe/types.ts"; import type { EventBus } from "../output/events.ts"; export type { RecipeFunction } from "../recipe/types.ts"; /** Options for runRecipe(). */ export type RunRecipeOptions = { /** Recipe function to execute, or path to a recipe .ts file to load. */ recipe: RecipeFunction | string; /** Hosts to run against. */ hosts: ReadonlyArray<{ host: HostContext; connection: Transport; }>; /** Run mode (apply or check). */ mode: RunMode; /** Error handling strategy. */ errorMode: ErrorMode; /** Verbose output. */ verbose: boolean; /** Reporter for output. */ reporter: Reporter; /** CLI variable overrides. */ vars?: Record | undefined; /** Optional recipe tag filter (intersection with recipe meta tags). */ tags?: string[] | undefined; /** Concurrency options for multi-host runs. */ concurrency?: Partial | undefined; /** Global resource execution policy (timeout/retry). */ resourcePolicy?: Partial | undefined; /** AbortSignal for run-level cancellation. */ signal?: AbortSignal | undefined; /** Optional check result cache. */ cache?: CheckResultCache | undefined; /** Optional event bus for lifecycle telemetry. */ eventBus?: EventBus | undefined; }; /** * Run a recipe against one or more hosts with bounded concurrency. * * Returns a RunSummary with per-host results in input order (deterministic). */ export declare function runRecipe(opts: RunRecipeOptions): Promise; //# sourceMappingURL=runner.d.ts.map