import type { GatewayServiceRuntime } from "./service-runtime.js"; import { enableSystemdUserLinger, readSystemdUserLingerStatus, type SystemdUserLingerStatus } from "./systemd-linger.js"; export declare function resolveSystemdUserUnitPath(env: Record): string; export { enableSystemdUserLinger, readSystemdUserLingerStatus }; export type { SystemdUserLingerStatus }; export declare function readSystemdServiceExecStart(env: Record): Promise<{ programArguments: string[]; workingDirectory?: string; environment?: Record; sourcePath?: string; } | null>; export type SystemdServiceInfo = { activeState?: string; subState?: string; mainPid?: number; execMainStatus?: number; execMainCode?: string; }; export declare function parseSystemdShow(output: string): SystemdServiceInfo; export declare function isSystemdUserServiceAvailable(): Promise; export declare function installSystemdService({ env, stdout, programArguments, workingDirectory, environment, description, }: { env: Record; stdout: NodeJS.WritableStream; programArguments: string[]; workingDirectory?: string; environment?: Record; description?: string; }): Promise<{ unitPath: string; }>; export declare function uninstallSystemdService({ env, stdout, }: { env: Record; stdout: NodeJS.WritableStream; }): Promise; export declare function stopSystemdService({ stdout, env, }: { stdout: NodeJS.WritableStream; env?: Record; }): Promise; export declare function restartSystemdService({ stdout, env, }: { stdout: NodeJS.WritableStream; env?: Record; }): Promise; export declare function isSystemdServiceEnabled(args: { env?: Record; }): Promise; export declare function readSystemdServiceRuntime(env?: Record): Promise; export type LegacySystemdUnit = { name: string; unitPath: string; enabled: boolean; exists: boolean; }; export declare function findLegacySystemdUnits(env: Record): Promise; export declare function uninstallLegacySystemdUnits({ env, stdout, }: { env: Record; stdout: NodeJS.WritableStream; }): Promise;