export interface ProcessCallbacks {
    onUnhealthy?: (reason: string) => void;
    onHealthy?: () => void;
}
export declare function findAvailablePort(startPort: number): Promise<number>;
interface LockResult {
    acquired: boolean;
    existingPid?: number;
    existingPort?: number;
}
export declare function isProcessAlive(pid: number): boolean;
export declare function acquireLock(dataDir: string): LockResult;
export declare function releaseLock(dataDir: string): void;
export declare class SearxngProcess {
    private readonly searxngPath;
    private readonly dataDir;
    private readonly callbacks;
    private child;
    private port;
    private crashTimes;
    private stopped;
    private isCurrentlyUnhealthy;
    private healthProbeFailures;
    private healthProbeTimer;
    constructor(searxngPath: string, dataDir: string, callbacks?: ProcessCallbacks);
    getUrl(): string | null;
    start(): Promise<string | null>;
    private monitorCrashes;
    private startHealthProbe;
    private probeOnce;
    private notePotentialFailure;
    stop(): Promise<void>;
}
export {};
//# sourceMappingURL=process.d.ts.map