2026-01-06 23:27:58 +01:00
|
|
|
export type GatewayDaemonRuntime = "node" | "bun";
|
|
|
|
|
|
|
|
|
|
export const DEFAULT_GATEWAY_DAEMON_RUNTIME: GatewayDaemonRuntime = "node";
|
|
|
|
|
|
|
|
|
|
export const GATEWAY_DAEMON_RUNTIME_OPTIONS: Array<{
|
|
|
|
|
value: GatewayDaemonRuntime;
|
|
|
|
|
label: string;
|
|
|
|
|
hint?: string;
|
|
|
|
|
}> = [
|
|
|
|
|
{
|
|
|
|
|
value: "node",
|
|
|
|
|
label: "Node (recommended)",
|
2026-01-08 22:15:46 +00:00
|
|
|
hint: "Required for WhatsApp + Telegram. Bun can corrupt memory on reconnect.",
|
2026-01-06 23:27:58 +01:00
|
|
|
},
|
|
|
|
|
];
|
|
|
|
|
|
2026-01-14 14:31:43 +00:00
|
|
|
export function isGatewayDaemonRuntime(value: string | undefined): value is GatewayDaemonRuntime {
|
2026-01-06 23:27:58 +01:00
|
|
|
return value === "node" || value === "bun";
|
|
|
|
|
}
|