export type SandboxMountMode = "none" | "read-only" | "read-write";
export interface SandboxRunOptions {
    command: string;
    workspaceRoot: string;
    timeoutMs: number;
    mountMode?: SandboxMountMode;
    networkEnabled?: boolean;
    memoryLimitMb?: number;
    cpuLimit?: string;
}
export interface SandboxRunResult {
    ok: boolean;
    output: string;
    exitCode: number | null;
    timedOut: boolean;
    containerName: string;
}
export interface SandboxSessionOptions {
    workspaceRoot: string;
    mountMode?: SandboxMountMode;
    networkEnabled?: boolean;
    memoryLimitMb?: number;
    cpuLimit?: string;
}
export interface SandboxSessionResult {
    containerName: string;
    workspaceRoot: string;
    sandboxWorkspaceRoot: string;
}
export interface SandboxExecOptions {
    containerName: string;
    command: string;
    timeoutMs: number;
}
export interface SandboxBrowserOptions {
    workspaceRoot: string;
    novncPort?: number;
    vncPort?: number;
    cdpPort?: number;
    waitForCdp?: boolean;
    mountMode?: SandboxMountMode;
    networkEnabled?: boolean;
    hostGateway?: boolean;
}
export interface SandboxBrowserResult {
    containerName: string;
    novncUrl: string;
    vncPort: number;
    novncPort: number;
    cdpUrl?: string;
}
export interface BrowserSandboxCleanupOptions {
    maxAgeMs?: number;
    excludeNames?: Iterable<string>;
}
interface ProcessResult {
    output: string;
    exitCode: number | null;
    timedOut: boolean;
}
export declare class SandboxManager {
    private readonly runProcess;
    constructor(runProcess?: (cmd: string[], timeoutMs: number) => Promise<ProcessResult>);
    runCommand(options: SandboxRunOptions): Promise<SandboxRunResult>;
    startCommandSandbox(options: SandboxSessionOptions): Promise<SandboxSessionResult>;
    execInContainer(options: SandboxExecOptions): Promise<SandboxRunResult>;
    startBrowserSandbox(options: SandboxBrowserOptions): Promise<SandboxBrowserResult>;
    stopContainer(containerName: string): Promise<void>;
    cleanupBrowserSandboxes(options?: BrowserSandboxCleanupOptions): Promise<string[]>;
    private buildMountArgs;
    private ensureBrowserSandboxImage;
    private cleanupConflictingBrowserSandboxes;
}
export declare function reserveLocalPort(): Promise<number>;
export {};
//# sourceMappingURL=sandbox-manager.d.ts.map