@songsid/agend 2.3.5-alpha.10 → 2.3.5-alpha.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/accounts-view.d.ts +17 -0
- package/dist/accounts-view.js +24 -8
- package/dist/accounts-view.js.map +1 -1
- package/dist/agent-cli-instructions.md +2 -2
- package/dist/auth-api.d.ts +48 -16
- package/dist/auth-api.js +83 -32
- package/dist/auth-api.js.map +1 -1
- package/dist/authority/settings-role.d.ts +56 -0
- package/dist/authority/settings-role.js +48 -0
- package/dist/authority/settings-role.js.map +1 -0
- package/dist/backend/claude-code.d.ts +2 -0
- package/dist/backend/claude-code.js +32 -6
- package/dist/backend/claude-code.js.map +1 -1
- package/dist/backend/cli-env-probe.js +6 -2
- package/dist/backend/cli-env-probe.js.map +1 -1
- package/dist/backend/codex.d.ts +5 -3
- package/dist/backend/codex.js +31 -13
- package/dist/backend/codex.js.map +1 -1
- package/dist/backend/credential-profile.d.ts +18 -0
- package/dist/backend/credential-profile.js +46 -0
- package/dist/backend/credential-profile.js.map +1 -1
- package/dist/backend/kiro.js +1 -1
- package/dist/backend/kiro.js.map +1 -1
- package/dist/backend/muse.d.ts +3 -1
- package/dist/backend/muse.js +31 -1
- package/dist/backend/muse.js.map +1 -1
- package/dist/backend/types.d.ts +17 -1
- package/dist/backend/types.js.map +1 -1
- package/dist/backend-availability.d.ts +15 -0
- package/dist/backend-availability.js +37 -1
- package/dist/backend-availability.js.map +1 -1
- package/dist/build-provenance.json +1 -1
- package/dist/bundled-tmux-guard.d.ts +4 -0
- package/dist/bundled-tmux-guard.js +7 -0
- package/dist/bundled-tmux-guard.js.map +1 -1
- package/dist/claude-auth-status.d.ts +20 -8
- package/dist/claude-auth-status.js +38 -22
- package/dist/claude-auth-status.js.map +1 -1
- package/dist/cli-audited.d.ts +60 -0
- package/dist/cli-audited.js +84 -0
- package/dist/cli-audited.js.map +1 -0
- package/dist/cli-capability.d.ts +36 -5
- package/dist/cli-capability.js +2 -2
- package/dist/cli-capability.js.map +1 -1
- package/dist/cli-caps-module.d.ts +5 -1
- package/dist/cli-caps-module.js +4 -2
- package/dist/cli-caps-module.js.map +1 -1
- package/dist/cli-registry-check.js +16 -2
- package/dist/cli-registry-check.js.map +1 -1
- package/dist/cli-registry.d.ts +56 -4
- package/dist/cli-registry.js +1 -1
- package/dist/cli-registry.js.map +1 -1
- package/dist/cli-spec-antigravity.d.ts +12 -1
- package/dist/cli-spec-antigravity.js +13 -1
- package/dist/cli-spec-antigravity.js.map +1 -1
- package/dist/cli-spec-claude-code.d.ts +9 -0
- package/dist/cli-spec-claude-code.js +4 -2
- package/dist/cli-spec-claude-code.js.map +1 -1
- package/dist/cli-spec-codex.d.ts +10 -1
- package/dist/cli-spec-codex.js +5 -3
- package/dist/cli-spec-codex.js.map +1 -1
- package/dist/cli-spec-grok.d.ts +5 -0
- package/dist/cli-spec-grok.js +6 -1
- package/dist/cli-spec-grok.js.map +1 -1
- package/dist/cli-spec-kiro-cli.d.ts +7 -1
- package/dist/cli-spec-kiro-cli.js +7 -3
- package/dist/cli-spec-kiro-cli.js.map +1 -1
- package/dist/cli-spec-muse.d.ts +2 -0
- package/dist/cli-spec-muse.js +3 -1
- package/dist/cli-spec-muse.js.map +1 -1
- package/dist/cli-spec-opencode.d.ts +11 -1
- package/dist/cli-spec-opencode.js +7 -2
- package/dist/cli-spec-opencode.js.map +1 -1
- package/dist/cli.js +28 -1
- package/dist/cli.js.map +1 -1
- package/dist/create-host-account.d.ts +17 -0
- package/dist/create-host-account.js +47 -0
- package/dist/create-host-account.js.map +1 -0
- package/dist/daemon.d.ts +26 -0
- package/dist/daemon.js +131 -10
- package/dist/daemon.js.map +1 -1
- package/dist/delivery-outbox.js +7 -0
- package/dist/delivery-outbox.js.map +1 -1
- package/dist/fleet-context.d.ts +5 -1
- package/dist/fleet-manager.d.ts +363 -71
- package/dist/fleet-manager.js +1374 -367
- package/dist/fleet-manager.js.map +1 -1
- package/dist/fleet-process-handlers.d.ts +1 -1
- package/dist/fleet-process-handlers.js +3 -2
- package/dist/fleet-process-handlers.js.map +1 -1
- package/dist/general-knowledge/skills/concepts/SKILL.md +21 -14
- package/dist/general-knowledge/skills/credential-profiles/SKILL.md +9 -8
- package/dist/general-knowledge/skills/cross-instance-messaging/SKILL.md +9 -1
- package/dist/general-knowledge/skills/kiro-engine-migration/SKILL.md +1 -1
- package/dist/general-knowledge/skills/web-dashboard/SKILL.md +27 -20
- package/dist/instance-lifecycle.js +33 -3
- package/dist/instance-lifecycle.js.map +1 -1
- package/dist/instructions.js +29 -6
- package/dist/instructions.js.map +1 -1
- package/dist/locale.js +125 -81
- package/dist/locale.js.map +1 -1
- package/dist/login-manager.d.ts +2 -2
- package/dist/login-manager.js +3 -2
- package/dist/login-manager.js.map +1 -1
- package/dist/native-model-catalog.d.ts +20 -0
- package/dist/native-model-catalog.js +107 -2
- package/dist/native-model-catalog.js.map +1 -1
- package/dist/public-web-gateway.js +1 -1
- package/dist/public-web-gateway.js.map +1 -1
- package/dist/public-web-link.d.ts +5 -0
- package/dist/public-web-link.js +8 -0
- package/dist/public-web-link.js.map +1 -1
- package/dist/runtime-api.d.ts +1 -1
- package/dist/runtime-api.js +104 -12
- package/dist/runtime-api.js.map +1 -1
- package/dist/runtime-autostart.d.ts +61 -0
- package/dist/runtime-autostart.js +161 -0
- package/dist/runtime-autostart.js.map +1 -0
- package/dist/runtime-background.d.ts +200 -0
- package/dist/runtime-background.js +480 -0
- package/dist/runtime-background.js.map +1 -0
- package/dist/runtime-build-info.js +5 -5
- package/dist/runtime-build-info.js.map +1 -1
- package/dist/runtime-cli-background.d.ts +92 -0
- package/dist/runtime-cli-background.js +336 -0
- package/dist/runtime-cli-background.js.map +1 -0
- package/dist/runtime-cli-install.d.ts +148 -8
- package/dist/runtime-cli-install.js +253 -59
- package/dist/runtime-cli-install.js.map +1 -1
- package/dist/runtime-cli.d.ts +8 -1
- package/dist/runtime-cli.js +206 -44
- package/dist/runtime-cli.js.map +1 -1
- package/dist/runtime-client-store.d.ts +11 -0
- package/dist/runtime-client-store.js +20 -5
- package/dist/runtime-client-store.js.map +1 -1
- package/dist/runtime-client.d.ts +23 -1
- package/dist/runtime-client.js +92 -6
- package/dist/runtime-client.js.map +1 -1
- package/dist/runtime-connection.d.ts +1 -1
- package/dist/runtime-connection.js +1 -1
- package/dist/runtime-connection.js.map +1 -1
- package/dist/runtime-coordinator.d.ts +95 -1
- package/dist/runtime-coordinator.js +344 -10
- package/dist/runtime-coordinator.js.map +1 -1
- package/dist/runtime-enroll-notice.d.ts +4 -0
- package/dist/runtime-enroll-notice.js +21 -0
- package/dist/runtime-enroll-notice.js.map +1 -0
- package/dist/runtime-enrollment.d.ts +21 -0
- package/dist/runtime-enrollment.js +52 -0
- package/dist/runtime-enrollment.js.map +1 -0
- package/dist/runtime-pane-native.js +4 -4
- package/dist/runtime-pane-native.js.map +1 -1
- package/dist/runtime-protocol.d.ts +78 -1
- package/dist/runtime-protocol.js +95 -5
- package/dist/runtime-protocol.js.map +1 -1
- package/dist/runtime-remote-accounts.d.ts +12 -0
- package/dist/runtime-remote-accounts.js +56 -5
- package/dist/runtime-remote-accounts.js.map +1 -1
- package/dist/runtime-remote-setup.d.ts +4 -1
- package/dist/runtime-remote-setup.js +4 -1
- package/dist/runtime-remote-setup.js.map +1 -1
- package/dist/runtime-update-controller.d.ts +11 -0
- package/dist/runtime-update-controller.js +56 -4
- package/dist/runtime-update-controller.js.map +1 -1
- package/dist/settings-api.d.ts +13 -1
- package/dist/settings-api.js +44 -20
- package/dist/settings-api.js.map +1 -1
- package/dist/settings-change.d.ts +5 -13
- package/dist/settings-change.js.map +1 -1
- package/dist/settings-confirmation.d.ts +11 -13
- package/dist/settings-confirmation.js +2 -6
- package/dist/settings-confirmation.js.map +1 -1
- package/dist/settings-effect.d.ts +5 -0
- package/dist/settings-effect.js +76 -10
- package/dist/settings-effect.js.map +1 -1
- package/dist/settings-http-confirmation.d.ts +8 -1
- package/dist/settings-http-confirmation.js +39 -13
- package/dist/settings-http-confirmation.js.map +1 -1
- package/dist/settings-request-capability.d.ts +7 -0
- package/dist/settings-request-capability.js +3 -1
- package/dist/settings-request-capability.js.map +1 -1
- package/dist/setup-i18n.js +4 -4
- package/dist/setup-i18n.js.map +1 -1
- package/dist/signin-keepalive.d.ts +25 -1
- package/dist/signin-keepalive.js +44 -1
- package/dist/signin-keepalive.js.map +1 -1
- package/dist/subagent-records.d.ts +45 -0
- package/dist/subagent-records.js +214 -0
- package/dist/subagent-records.js.map +1 -0
- package/dist/subagent-service.d.ts +27 -0
- package/dist/subagent-service.js +199 -0
- package/dist/subagent-service.js.map +1 -0
- package/dist/tmux-manager.d.ts +2 -2
- package/dist/tmux-manager.js +5 -3
- package/dist/tmux-manager.js.map +1 -1
- package/dist/ui/account-identity.js +7 -5
- package/dist/ui/accounts-keepalive.js +17 -17
- package/dist/ui/accounts-manage.js +34 -34
- package/dist/ui/accounts-view.js +68 -24
- package/dist/ui/agent-runtime-settings.js +1 -1
- package/dist/ui/backend-signin.js +67 -67
- package/dist/ui/chat-msg-actions.js +50 -4
- package/dist/ui/chat-quote.js +256 -0
- package/dist/ui/chat-store.js +9 -4
- package/dist/ui/cli-caps.js +7 -7
- package/dist/ui/credential-profile-select.js +4 -4
- package/dist/ui/general-location.js +1 -1
- package/dist/ui/host-install.js +290 -0
- package/dist/ui/hub-company-join-strings.js +3 -0
- package/dist/ui/hub-company-join.js +20 -2
- package/dist/ui/hub-owner-strings.js +5 -4
- package/dist/ui/hub-pairing-progress-strings.js +1 -1
- package/dist/ui/hub-quick-strings.js +4 -4
- package/dist/ui/hub-strings.js +6 -6
- package/dist/ui/machine-signin.js +4 -4
- package/dist/ui/model-picker.js +68 -0
- package/dist/ui/panel-chat.js +74 -13
- package/dist/ui/panel-fleet.js +8 -2
- package/dist/ui/panel-hub.js +8 -4
- package/dist/ui/panel-needs.js +2 -2
- package/dist/ui/panel-runtimes.js +232 -33
- package/dist/ui/panel-settings.js +7 -1
- package/dist/ui/panel-windows-cli.js +1 -1
- package/dist/ui/runtime-cli-install.js +99 -20
- package/dist/ui/runtime-commands.d.ts +2 -0
- package/dist/ui/runtime-commands.js +34 -1
- package/dist/ui/runtime-update-status.js +2 -2
- package/dist/ui/search-dialog.js +1 -0
- package/dist/ui/settings-access-overview.js +167 -0
- package/dist/ui/settings-access-strings.js +1 -1
- package/dist/ui/settings-catalog.js +19 -3
- package/dist/ui/settings-confirm.js +2 -2
- package/dist/ui/settings-devices.js +59 -25
- package/dist/ui/settings-dialogs.js +12 -13
- package/dist/ui/settings-guests.js +1 -1
- package/dist/ui/settings-hub-company-join.js +10 -7
- package/dist/ui/settings-hub-connection.js +121 -0
- package/dist/ui/settings-hub-membership.js +1 -1
- package/dist/ui/settings-hub-run.js +5 -6
- package/dist/ui/settings-hub-section.js +3 -6
- package/dist/ui/settings-hub.js +12 -7
- package/dist/ui/settings-layout.js +9 -7
- package/dist/ui/settings-outside.js +87 -19
- package/dist/ui/settings-registry.js +2 -1
- package/dist/ui/settings-revoke-strings.js +28 -0
- package/dist/ui/settings-strings.js +25 -25
- package/dist/ui/settings-web-authority.js +11 -4
- package/dist/ui/shared/accounts.css +11 -1
- package/dist/ui/shared/agend-auth.js +8 -1
- package/dist/ui/shared/app-i18n.js +10 -12
- package/dist/ui/shared/app-session.js +13 -16
- package/dist/ui/shared/app-shell.js +37 -37
- package/dist/ui/shared/app-store.js +2 -0
- package/dist/ui/shared/app.css +85 -14
- package/dist/ui/shared/chat-render.js +17 -5
- package/dist/ui/shared/chat-strings.js +4 -4
- package/dist/ui/shared/device-roles.js +27 -0
- package/dist/ui/shared/host-install.css +10 -0
- package/dist/ui/shared/hub-owner.css +6 -0
- package/dist/ui/shared/model-picker.css +21 -0
- package/dist/ui/shared/runtime-install.css +26 -1
- package/dist/ui/shared/setup-host-text.js +4 -4
- package/dist/ui/shared/signin.js +171 -64
- package/dist/ui/shared/subagent-row.css +15 -0
- package/dist/ui/shared/usage-dialog.js +28 -16
- package/dist/ui/shared/view-strings.js +7 -7
- package/dist/ui/shared/web-authorize.js +54 -4
- package/dist/ui/signin.html +19 -8
- package/dist/ui/structured-signin.js +30 -30
- package/dist/ui/subagent-row.js +72 -0
- package/dist/ui/web-terminal/terminal.js +9 -9
- package/dist/update-launch.js +4 -1
- package/dist/update-launch.js.map +1 -1
- package/dist/update-npm-env.d.ts +70 -0
- package/dist/update-npm-env.js +128 -0
- package/dist/update-npm-env.js.map +1 -0
- package/dist/usage/format-rich.js +1 -1
- package/dist/usage/format-rich.js.map +1 -1
- package/dist/usage/providers.js +2 -2
- package/dist/usage/providers.js.map +1 -1
- package/dist/usage/usage-api.d.ts +8 -2
- package/dist/usage/usage-api.js +12 -5
- package/dist/usage/usage-api.js.map +1 -1
- package/dist/web-api.d.ts +38 -4
- package/dist/web-api.js +370 -18
- package/dist/web-api.js.map +1 -1
- package/dist/web-auth.js +1 -1
- package/dist/web-auth.js.map +1 -1
- package/dist/web-backend-login.d.ts +2 -0
- package/dist/web-backend-login.js.map +1 -1
- package/dist/web-channel-echo.js +3 -1
- package/dist/web-channel-echo.js.map +1 -1
- package/dist/web-commands.d.ts +9 -1
- package/dist/web-commands.js +7 -1
- package/dist/web-commands.js.map +1 -1
- package/dist/web-host-install.d.ts +127 -0
- package/dist/web-host-install.js +165 -0
- package/dist/web-host-install.js.map +1 -0
- package/dist/web-remote-access.d.ts +194 -11
- package/dist/web-remote-access.js +458 -34
- package/dist/web-remote-access.js.map +1 -1
- package/dist/web-session.d.ts +11 -3
- package/dist/web-session.js.map +1 -1
- package/dist/web-signin-device.d.ts +16 -0
- package/dist/web-signin-device.js +81 -0
- package/dist/web-signin-device.js.map +1 -0
- package/dist/web-update.js +3 -1
- package/dist/web-update.js.map +1 -1
- package/dist/windows-cli-api.js +2 -1
- package/dist/windows-cli-api.js.map +1 -1
- package/dist/windows-cli-worker.d.ts +14 -0
- package/dist/windows-cli-worker.js +145 -1
- package/dist/windows-cli-worker.js.map +1 -1
- package/dist/windows-cli.d.ts +4 -0
- package/dist/windows-cli.js +9 -1
- package/dist/windows-cli.js.map +1 -1
- package/launcher/agend-install.cjs +16 -3
- package/package.json +1 -1
- package/templates/runtime-install/install.ps1 +219 -12
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import { type RuntimeClientStore } from "./runtime-client-store.js";
|
|
2
|
+
import { type AutostartService } from "./runtime-autostart.js";
|
|
3
|
+
import { RUNTIME_BACKGROUND_ENV, type BackgroundLaunchOptions, type BackgroundLaunchResult, type InstanceDeps, type RuntimeInstance } from "./runtime-background.js";
|
|
4
|
+
export interface BackgroundSeams {
|
|
5
|
+
/** The `runtime-cli.js` that is running; the launcher starts this file. */
|
|
6
|
+
cliPath?: string;
|
|
7
|
+
launch?: (options: BackgroundLaunchOptions) => Promise<BackgroundLaunchResult>;
|
|
8
|
+
autostart?: AutostartService;
|
|
9
|
+
instance?: InstanceDeps;
|
|
10
|
+
/** How long `stop` and `restart` wait for the Runtime to end, and how long a launch waits for "connected". */
|
|
11
|
+
stopTimeoutMs?: number;
|
|
12
|
+
waitMs?: number;
|
|
13
|
+
/** How often the background Runtime looks for a stop request. */
|
|
14
|
+
watchMs?: number;
|
|
15
|
+
}
|
|
16
|
+
export interface BackgroundContext {
|
|
17
|
+
env: NodeJS.ProcessEnv;
|
|
18
|
+
home: string;
|
|
19
|
+
cliPath: string;
|
|
20
|
+
execPath: string;
|
|
21
|
+
seams: BackgroundSeams;
|
|
22
|
+
write: (text: string) => void;
|
|
23
|
+
}
|
|
24
|
+
/** How to type this Runtime's command on this computer: `agend-runtime` when the installer's bin folder is on PATH, else the file that starts it. */
|
|
25
|
+
export declare function runtimeCommandName(cliPath: string, env?: NodeJS.ProcessEnv, exists?: (path: string) => boolean): string;
|
|
26
|
+
export interface LaunchInput {
|
|
27
|
+
store: RuntimeClientStore; /** Turn the sign-in task on when this profile never chose (connect and start-after-pairing do; the task's own `start` does not). */
|
|
28
|
+
enableAutostartByDefault: boolean;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Starts the profile's Runtime in the background unless one already runs for it. Exit status for the caller: 0 when a Runtime is running afterwards
|
|
32
|
+
* (started, still connecting, or already there), and a thrown error when it could not be started or stopped before it connected.
|
|
33
|
+
*/
|
|
34
|
+
export declare function launchInBackground(context: BackgroundContext, input: LaunchInput): Promise<void>;
|
|
35
|
+
export declare function enableAutostart(context: BackgroundContext, store: RuntimeClientStore): Promise<void>;
|
|
36
|
+
export declare function disableAutostart(context: BackgroundContext, store: RuntimeClientStore): Promise<boolean>;
|
|
37
|
+
export interface Selection {
|
|
38
|
+
explicit?: string;
|
|
39
|
+
connectionProfile?: string;
|
|
40
|
+
}
|
|
41
|
+
export interface ProfileStatus {
|
|
42
|
+
label: string;
|
|
43
|
+
profile: string;
|
|
44
|
+
instance: RuntimeInstance;
|
|
45
|
+
autostart: {
|
|
46
|
+
enabled: boolean | undefined;
|
|
47
|
+
task: boolean | undefined;
|
|
48
|
+
taskName: string;
|
|
49
|
+
};
|
|
50
|
+
logs: string;
|
|
51
|
+
}
|
|
52
|
+
/** `describe` adds the profile's own details (pairing, jobs, credential profiles); this adds what belongs to running in the background. */
|
|
53
|
+
export declare function profileStatus(context: BackgroundContext, store: RuntimeClientStore, deps: InstanceDeps): Promise<ProfileStatus>;
|
|
54
|
+
export declare function formatProfileStatus(status: ProfileStatus, details: {
|
|
55
|
+
server?: string;
|
|
56
|
+
name?: string;
|
|
57
|
+
paired: boolean;
|
|
58
|
+
blocked: boolean;
|
|
59
|
+
}): string;
|
|
60
|
+
export interface ManageInput {
|
|
61
|
+
command: "status" | "stop" | "restart" | "logs" | "autostart";
|
|
62
|
+
selection: Selection;
|
|
63
|
+
all: boolean;
|
|
64
|
+
tail?: number;
|
|
65
|
+
action?: string;
|
|
66
|
+
openStore: (directory: string) => RuntimeClientStore;
|
|
67
|
+
/** status: the profile's own details as the `status --json` entry; the background part is added here. */
|
|
68
|
+
describe: (store: RuntimeClientStore) => Record<string, unknown> & {
|
|
69
|
+
paired: boolean;
|
|
70
|
+
blocked: boolean;
|
|
71
|
+
server?: string;
|
|
72
|
+
name?: string;
|
|
73
|
+
};
|
|
74
|
+
json: boolean;
|
|
75
|
+
runtimeInfo: unknown;
|
|
76
|
+
}
|
|
77
|
+
export declare function manageBackground(context: BackgroundContext, input: ManageInput): Promise<void>;
|
|
78
|
+
/** What `disconnect` does beyond forgetting the pairing: ends the background Runtime first (there is no window to close), then removes the sign-in task. */
|
|
79
|
+
export declare function stopForDisconnect(context: BackgroundContext, store: RuntimeClientStore): Promise<void>;
|
|
80
|
+
export declare function removeAutostartForDisconnect(context: BackgroundContext, store: RuntimeClientStore): Promise<void>;
|
|
81
|
+
/** `control.onStopAttempt` hands over the Runtime's own stop attempt (it settles when the attempt did, whether or not the shutdown was confirmed), so a stop request is one attempt at a time. */
|
|
82
|
+
export interface BackgroundRun {
|
|
83
|
+
run: (report: (text: string) => void, control?: {
|
|
84
|
+
onStopAttempt: (attempt: () => Promise<void>) => void;
|
|
85
|
+
}) => Promise<void>;
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* What the detached `run` process does around the normal Runtime: its output goes to the log, a stop request ends it the way Ctrl+C would, the launcher is told
|
|
89
|
+
* when AgEnD welcomed it (or that it failed, or that another Runtime already holds the profile) through the state file, and the marker `status` reads is kept while it runs.
|
|
90
|
+
*/
|
|
91
|
+
export declare function runBackgroundInstance(context: BackgroundContext, store: RuntimeClientStore, body: BackgroundRun, runtimeVersion?: string): Promise<void>;
|
|
92
|
+
export { RUNTIME_BACKGROUND_ENV };
|
|
@@ -0,0 +1,336 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* the commands and flows that keep the Windows Runtime in the background: `connect` and `start` launch it detached, `status`, `stop`, `restart`,
|
|
3
|
+
* `logs` and `autostart` manage it, and `runBackgroundInstance` is what the detached process itself runs. Split from runtime-cli.ts so that file stays the
|
|
4
|
+
* argument parser and the pairing flow.
|
|
5
|
+
*/
|
|
6
|
+
import { existsSync } from "node:fs";
|
|
7
|
+
import { dirname, join, resolve } from "node:path";
|
|
8
|
+
import { RuntimeProfileInUseError } from "./runtime-client-store.js";
|
|
9
|
+
import { RUNTIME_CONNECTED_REPORT } from "./runtime-client.js";
|
|
10
|
+
import { readPaneSystemBootId, reusedRuntimeLockPid } from "./runtime-pane-boot.js";
|
|
11
|
+
import { createAutostartService, autostartTaskName } from "./runtime-autostart.js";
|
|
12
|
+
import { RUNTIME_BACKGROUND_ENV, RotatingLog, captureProcessOutput, clearInstanceMarker, clearStopRequest, discoverRuntimeProfiles, forgetRuntimeProfileNote, launchBackgroundRuntime, noteRuntimeProfile, readAutostartPreference, readRuntimeInstance, reportBackgroundState, runtimeLogDirectory, runtimeProfileLabel, stopRuntimeInstance, watchStopRequest, writeAutostartPreference, writeInstanceMarker } from "./runtime-background.js";
|
|
13
|
+
const out = (context, text) => context.write(`${text}\n`);
|
|
14
|
+
function instanceDeps(context) {
|
|
15
|
+
// One read of the Windows boot identity for every profile a command looks at (it starts PowerShell).
|
|
16
|
+
let boot;
|
|
17
|
+
return { systemBootId: () => boot ??= readPaneSystemBootId(), reusedPid: holder => reusedRuntimeLockPid(holder), ...(context.seams.instance ?? {}) };
|
|
18
|
+
}
|
|
19
|
+
const autostartService = (context) => context.seams.autostart ?? createAutostartService();
|
|
20
|
+
const logFor = (context, store) => new RotatingLog(runtimeLogDirectory(context.env, context.home, store.directory));
|
|
21
|
+
/** How to type this Runtime's command on this computer: `agend-runtime` when the installer's bin folder is on PATH, else the file that starts it. */
|
|
22
|
+
export function runtimeCommandName(cliPath, env = process.env, exists = existsSync) {
|
|
23
|
+
const versionFolder = dirname(dirname(cliPath));
|
|
24
|
+
const shims = [join(dirname(versionFolder), "bin", "agend-runtime.cmd"), join(versionFolder, "agend-runtime.cmd")];
|
|
25
|
+
const shim = shims.find(path => exists(path));
|
|
26
|
+
if (!shim)
|
|
27
|
+
return `node.exe "${cliPath}"`;
|
|
28
|
+
const folder = dirname(shim).replace(/[\\/]+$/, "").toLowerCase();
|
|
29
|
+
const onPath = String(env.Path ?? env.PATH ?? "").split(";").some(entry => entry.trim().replace(/[\\/]+$/, "").toLowerCase() === folder);
|
|
30
|
+
return onPath ? "agend-runtime" : `"${shim}"`;
|
|
31
|
+
}
|
|
32
|
+
function manageLines(context, store) {
|
|
33
|
+
const name = runtimeCommandName(context.cliPath, context.env);
|
|
34
|
+
return [` Check it: ${name} status`, ` Stop it: ${name} stop`, ` Read its log: ${name} logs (${runtimeLogDirectory(context.env, context.home, store.directory)})`];
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* Starts the profile's Runtime in the background unless one already runs for it. Exit status for the caller: 0 when a Runtime is running afterwards
|
|
38
|
+
* (started, still connecting, or already there), and a thrown error when it could not be started or stopped before it connected.
|
|
39
|
+
*/
|
|
40
|
+
export async function launchInBackground(context, input) {
|
|
41
|
+
const { store } = input, label = runtimeProfileLabel(store.directory, context.home), log = logFor(context, store);
|
|
42
|
+
const existing = await readRuntimeInstance(store, instanceDeps(context));
|
|
43
|
+
let pid = existing.pid;
|
|
44
|
+
// Autostart is turned on by default only for a Runtime that is connected (or already runs in the background): not while the one just started is still connecting,
|
|
45
|
+
// not when a window's Runtime was found (the person chose a window), and not when another start won the race and its state is unknown here.
|
|
46
|
+
let connected = existing.state === "running" && existing.mode === "background";
|
|
47
|
+
if (existing.state === "running") {
|
|
48
|
+
log.write(`start: a Runtime already runs for this profile (process ${existing.pid}); nothing started.`);
|
|
49
|
+
out(context, `AgEnD Runtime is already running for this profile (${label}, process ${existing.pid}${existing.mode === "foreground" ? ", in a window" : ", in the background"}). Nothing was started.`);
|
|
50
|
+
}
|
|
51
|
+
else {
|
|
52
|
+
noteRuntimeProfile(context.env, context.home, store.directory);
|
|
53
|
+
const launch = context.seams.launch ?? launchBackgroundRuntime;
|
|
54
|
+
const result = await launch({ store, cliPath: context.cliPath, execPath: context.execPath, env: context.env, log, ...(context.seams.waitMs !== undefined ? { waitMs: context.seams.waitMs } : {}) });
|
|
55
|
+
if (result.kind === "failed")
|
|
56
|
+
throw new Error(result.message);
|
|
57
|
+
if (result.kind === "already-running")
|
|
58
|
+
out(context, `AgEnD Runtime is already running for this profile (${label}${result.pid ? `, process ${result.pid}` : ""}). Nothing was started.`);
|
|
59
|
+
else {
|
|
60
|
+
pid = result.pid;
|
|
61
|
+
connected = result.connected === true;
|
|
62
|
+
out(context, result.connected
|
|
63
|
+
? `AgEnD Runtime is connected and running in the background (${label}, process ${result.pid}). Closing this window does not disconnect it.`
|
|
64
|
+
: `AgEnD Runtime was started in the background (${label}, process ${result.pid}) but has not connected yet. It keeps trying by itself, and closing this window does not stop it. If it stays offline, run ${runtimeCommandName(context.cliPath, context.env)} logs to see why.`);
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
if (input.enableAutostartByDefault && connected && readAutostartPreference(store.directory) === undefined) {
|
|
68
|
+
try {
|
|
69
|
+
await enableAutostart(context, store);
|
|
70
|
+
}
|
|
71
|
+
catch (error) {
|
|
72
|
+
out(context, `Autostart could not be turned on: ${error instanceof Error ? error.message : "unknown error"}`);
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
if (pid)
|
|
76
|
+
for (const line of manageLines(context, store))
|
|
77
|
+
out(context, line);
|
|
78
|
+
const preference = readAutostartPreference(store.directory);
|
|
79
|
+
if (preference === true)
|
|
80
|
+
out(context, ` It starts again by itself when you sign in to Windows (turn that off: ${runtimeCommandName(context.cliPath, context.env)} autostart disable).`);
|
|
81
|
+
}
|
|
82
|
+
/* ------------------------------------------------------------------ autostart */
|
|
83
|
+
export async function enableAutostart(context, store) {
|
|
84
|
+
const label = runtimeProfileLabel(store.directory, context.home);
|
|
85
|
+
await autostartService(context).enable({ label, profile: store.directory, cliPath: context.cliPath, execPath: context.execPath, workFolder: runtimeLogDirectory(context.env, context.home, store.directory) });
|
|
86
|
+
writeAutostartPreference(store.directory, true);
|
|
87
|
+
noteRuntimeProfile(context.env, context.home, store.directory);
|
|
88
|
+
}
|
|
89
|
+
export async function disableAutostart(context, store) {
|
|
90
|
+
const removed = await autostartService(context).disable(runtimeProfileLabel(store.directory, context.home));
|
|
91
|
+
writeAutostartPreference(store.directory, false);
|
|
92
|
+
return removed;
|
|
93
|
+
}
|
|
94
|
+
/**
|
|
95
|
+
* The profiles a management command acts on. A name given with --profile (or AGEND_RUNTIME_HOME) is a profile label shown by `status` or a folder; with
|
|
96
|
+
* --connection-dir it is the profile that folder's address picks. With none of them, every profile this computer knows.
|
|
97
|
+
*/
|
|
98
|
+
function targets(context, selection) {
|
|
99
|
+
const known = discoverRuntimeProfiles(context.env, context.home);
|
|
100
|
+
if (selection.explicit) {
|
|
101
|
+
const byLabel = !/[\\/:]/.test(selection.explicit) ? known.find(profile => profile.label === selection.explicit) : undefined;
|
|
102
|
+
const directory = byLabel?.directory ?? resolve(selection.explicit);
|
|
103
|
+
// A name or folder that is not a Runtime profile is an error, not a new empty profile (opening a profile creates its folder).
|
|
104
|
+
if (!existsSync(directory))
|
|
105
|
+
throw new Error(`There is no Runtime profile ${byLabel ? "named" : "folder"} "${selection.explicit}" on this computer. ${known.length ? `Known profiles: ${describeChoice(known)}.` : "agend-runtime status lists them once one is connected."}`);
|
|
106
|
+
return { profiles: [{ label: runtimeProfileLabel(directory, context.home), directory }], chosen: true };
|
|
107
|
+
}
|
|
108
|
+
if (selection.connectionProfile)
|
|
109
|
+
return { profiles: [{ label: runtimeProfileLabel(selection.connectionProfile, context.home), directory: resolve(selection.connectionProfile) }], chosen: true };
|
|
110
|
+
return { profiles: known, chosen: false };
|
|
111
|
+
}
|
|
112
|
+
/** `describe` adds the profile's own details (pairing, jobs, credential profiles); this adds what belongs to running in the background. */
|
|
113
|
+
export async function profileStatus(context, store, deps) {
|
|
114
|
+
const label = runtimeProfileLabel(store.directory, context.home);
|
|
115
|
+
let task;
|
|
116
|
+
if (process.platform === "win32" || context.seams.autostart) {
|
|
117
|
+
try {
|
|
118
|
+
task = await autostartService(context).exists(label);
|
|
119
|
+
}
|
|
120
|
+
catch {
|
|
121
|
+
task = undefined;
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
return { label, profile: store.directory, instance: await readRuntimeInstance(store, deps), autostart: { enabled: readAutostartPreference(store.directory), task, taskName: autostartTaskName(label) },
|
|
125
|
+
logs: runtimeLogDirectory(context.env, context.home, store.directory) };
|
|
126
|
+
}
|
|
127
|
+
function sinceText(at) { return at ? `, since ${new Date(at).toLocaleString()}` : ""; }
|
|
128
|
+
export function formatProfileStatus(status, details) {
|
|
129
|
+
const state = status.instance.state === "running"
|
|
130
|
+
? `running ${status.instance.mode === "background" ? "in the background" : "in a window"} (process ${status.instance.pid}${sinceText(status.instance.startedAt)})`
|
|
131
|
+
: "not running";
|
|
132
|
+
const autostart = status.autostart.enabled === false ? "off"
|
|
133
|
+
: status.autostart.task === true ? `on (scheduled task "${status.autostart.taskName}")`
|
|
134
|
+
: status.autostart.enabled === true ? (status.autostart.task === false ? "on, but the scheduled task is missing: run autostart enable again" : "on")
|
|
135
|
+
: "not set up yet";
|
|
136
|
+
return [`${status.label}`, ` state: ${state}`,
|
|
137
|
+
` server: ${details.paired ? details.server ?? "?" : "not paired yet"}${details.paired && details.name ? ` (this computer: ${details.name})` : ""}`,
|
|
138
|
+
` autostart: ${autostart}`, ...(details.blocked ? [" jobs: an unfinished job is recorded in this profile; see status --json"] : []),
|
|
139
|
+
` profile: ${status.profile}`, ` logs: ${status.logs}`].join("\n");
|
|
140
|
+
}
|
|
141
|
+
function describeChoice(profiles) { return profiles.map(profile => `${profile.label} (${profile.directory})`).join(", "); }
|
|
142
|
+
function unknownProfile() { return new Error("No AgEnD Runtime profile was found on this computer. Connect one first (connect-agend.bat or the install command from AgEnD Settings -> Runtime), or name a folder with --profile."); }
|
|
143
|
+
export async function manageBackground(context, input) {
|
|
144
|
+
const deps = instanceDeps(context), { profiles, chosen } = targets(context, input.selection);
|
|
145
|
+
if (input.command === "status") {
|
|
146
|
+
if (!profiles.length) {
|
|
147
|
+
if (input.json)
|
|
148
|
+
out(context, JSON.stringify({ runtimeInfo: input.runtimeInfo, profiles: [] }, null, 2));
|
|
149
|
+
else
|
|
150
|
+
out(context, "No AgEnD Runtime profile was found on this computer. Connect one with connect-agend.bat or the install command from AgEnD Settings -> Runtime.");
|
|
151
|
+
return;
|
|
152
|
+
}
|
|
153
|
+
const entries = [];
|
|
154
|
+
for (const profile of profiles) {
|
|
155
|
+
const store = input.openStore(profile.directory);
|
|
156
|
+
entries.push({ status: await profileStatus(context, store, deps), details: input.describe(store) });
|
|
157
|
+
}
|
|
158
|
+
if (input.json) {
|
|
159
|
+
out(context, JSON.stringify({ runtimeInfo: input.runtimeInfo, profiles: entries.map(({ status, details }) => ({ ...details, label: status.label, background: { state: status.instance.state, ...(status.instance.pid ? { pid: status.instance.pid } : {}), ...(status.instance.mode ? { mode: status.instance.mode } : {}), ...(status.instance.startedAt ? { startedAt: status.instance.startedAt } : {}) },
|
|
160
|
+
autostart: status.autostart, logs: status.logs })) }, null, 2));
|
|
161
|
+
return;
|
|
162
|
+
}
|
|
163
|
+
out(context, entries.map(({ status, details }) => formatProfileStatus(status, details)).join("\n\n"));
|
|
164
|
+
return;
|
|
165
|
+
}
|
|
166
|
+
if (!profiles.length)
|
|
167
|
+
throw unknownProfile();
|
|
168
|
+
if (input.command === "logs") {
|
|
169
|
+
if (profiles.length > 1)
|
|
170
|
+
throw new Error(`Several profiles have a log. Choose one with --profile: ${describeChoice(profiles)}.`);
|
|
171
|
+
const store = input.openStore(profiles[0].directory), log = logFor(context, store), lines = log.tail(input.tail ?? 50);
|
|
172
|
+
if (!lines.length) {
|
|
173
|
+
out(context, `No log yet for ${profiles[0].label} (${log.directory}). A Runtime that runs in the background writes it.`);
|
|
174
|
+
return;
|
|
175
|
+
}
|
|
176
|
+
out(context, lines.join("\n"));
|
|
177
|
+
return;
|
|
178
|
+
}
|
|
179
|
+
if (input.command === "autostart") {
|
|
180
|
+
if (profiles.length > 1)
|
|
181
|
+
throw new Error(`Several profiles exist. Choose one with --profile: ${describeChoice(profiles)}.`);
|
|
182
|
+
const store = input.openStore(profiles[0].directory), label = profiles[0].label, name = runtimeCommandName(context.cliPath, context.env);
|
|
183
|
+
if (input.action === "enable") {
|
|
184
|
+
if (process.platform !== "win32" && !context.seams.autostart)
|
|
185
|
+
throw new Error("Autostart uses the Windows Task Scheduler and needs native Windows.");
|
|
186
|
+
if (!store.credentials())
|
|
187
|
+
throw new Error("This profile is not paired yet, so there is nothing to start at sign-in. Connect it first.");
|
|
188
|
+
await enableAutostart(context, store);
|
|
189
|
+
out(context, `Autostart is on for ${label}: the Runtime starts by itself when you sign in to Windows (scheduled task "${autostartTaskName(label)}", your own account, no administrator rights). Turn it off: ${name} autostart disable`);
|
|
190
|
+
}
|
|
191
|
+
else if (input.action === "disable") {
|
|
192
|
+
const removed = await disableAutostart(context, store);
|
|
193
|
+
out(context, `Autostart is off for ${label}${removed ? ": the scheduled task was removed" : " (there was no scheduled task)"}. The Runtime keeps running if it is running; it will not start again by itself after you sign out. Turn it on: ${name} autostart enable`);
|
|
194
|
+
}
|
|
195
|
+
else {
|
|
196
|
+
const status = await profileStatus(context, store, deps);
|
|
197
|
+
out(context, `Autostart for ${label}: ${status.autostart.enabled === false ? "off" : status.autostart.enabled === true ? (status.autostart.task === false ? "on, but the scheduled task is missing (run autostart enable again)" : "on") : "not set up yet (it turns on the first time connect succeeds in the background)"}.`);
|
|
198
|
+
}
|
|
199
|
+
return;
|
|
200
|
+
}
|
|
201
|
+
// stop and restart act on Runtimes that run, and never on more than one by surprise.
|
|
202
|
+
const running = [];
|
|
203
|
+
for (const profile of profiles) {
|
|
204
|
+
const instance = await readRuntimeInstance(input.openStore(profile.directory), deps);
|
|
205
|
+
if (instance.state === "running")
|
|
206
|
+
running.push({ profile, instance });
|
|
207
|
+
}
|
|
208
|
+
const verb = input.command === "stop" ? "stop" : "restart";
|
|
209
|
+
if (!running.length) {
|
|
210
|
+
out(context, `No Runtime is running${chosen ? " for that profile" : ""}, so there is nothing to ${verb}.${input.command === "restart" ? ` Start one with ${runtimeCommandName(context.cliPath, context.env)} start.` : ""}`);
|
|
211
|
+
return;
|
|
212
|
+
}
|
|
213
|
+
if (running.length > 1 && !input.all)
|
|
214
|
+
throw new Error(`Several Runtimes are running: ${describeChoice(running.map(row => row.profile))}. Name one with --profile, or use --all to ${verb} every one.`);
|
|
215
|
+
let failure;
|
|
216
|
+
for (const { profile, instance } of running) {
|
|
217
|
+
const store = input.openStore(profile.directory);
|
|
218
|
+
try {
|
|
219
|
+
if (instance.mode === "foreground")
|
|
220
|
+
throw new Error(`${profile.label}: the Runtime (process ${instance.pid}) runs in a window, not in the background. Press Ctrl+C in that window.`);
|
|
221
|
+
const outcome = await stopRuntimeInstance(store, { deps, ...(context.seams.stopTimeoutMs !== undefined ? { timeoutMs: context.seams.stopTimeoutMs } : {}) });
|
|
222
|
+
if (outcome === "timeout")
|
|
223
|
+
throw new Error(`${profile.label}: the Runtime (process ${instance.pid}) did not stop within ${Math.round((context.seams.stopTimeoutMs ?? 30_000) / 1000)} seconds. It may be finishing work; run ${runtimeCommandName(context.cliPath, context.env)} stop again, or end that process in Task Manager.`);
|
|
224
|
+
if (input.command === "stop") {
|
|
225
|
+
out(context, `${profile.label}: stopped.`);
|
|
226
|
+
if (readAutostartPreference(store.directory) === true)
|
|
227
|
+
out(context, ` It starts again when you sign in to Windows. To keep it off: ${runtimeCommandName(context.cliPath, context.env)} autostart disable`);
|
|
228
|
+
}
|
|
229
|
+
else {
|
|
230
|
+
out(context, `${profile.label}: stopped; starting it again with the installed version.`);
|
|
231
|
+
await launchInBackground(context, { store, enableAutostartByDefault: false });
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
catch (error) {
|
|
235
|
+
failure ??= error instanceof Error ? error : new Error("The Runtime could not be stopped");
|
|
236
|
+
out(context, error instanceof Error ? error.message : "The Runtime could not be stopped");
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
if (failure)
|
|
240
|
+
throw new Error(`Not every Runtime was ${input.command === "stop" ? "stopped" : "restarted"}.`);
|
|
241
|
+
}
|
|
242
|
+
/** What `disconnect` does beyond forgetting the pairing: ends the background Runtime first (there is no window to close), then removes the sign-in task. */
|
|
243
|
+
export async function stopForDisconnect(context, store) {
|
|
244
|
+
const deps = instanceDeps(context), instance = await readRuntimeInstance(store, deps);
|
|
245
|
+
if (instance.state !== "running" || instance.mode !== "background")
|
|
246
|
+
return;
|
|
247
|
+
out(context, `Stopping the Runtime that runs in the background (process ${instance.pid}) first…`);
|
|
248
|
+
const outcome = await stopRuntimeInstance(store, { deps, ...(context.seams.stopTimeoutMs !== undefined ? { timeoutMs: context.seams.stopTimeoutMs } : {}) });
|
|
249
|
+
if (outcome === "timeout")
|
|
250
|
+
throw new Error(`The background Runtime (process ${instance.pid}) did not stop in time, so nothing was disconnected. Run ${runtimeCommandName(context.cliPath, context.env)} stop, then disconnect again.`);
|
|
251
|
+
}
|
|
252
|
+
export async function removeAutostartForDisconnect(context, store) {
|
|
253
|
+
const label = runtimeProfileLabel(store.directory, context.home);
|
|
254
|
+
try {
|
|
255
|
+
if (process.platform === "win32" || context.seams.autostart) {
|
|
256
|
+
if (await autostartService(context).disable(label))
|
|
257
|
+
out(context, "The sign-in task that started this Runtime was removed.");
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
catch (error) {
|
|
261
|
+
out(context, `The sign-in task could not be removed: ${error instanceof Error ? error.message : "unknown error"}`);
|
|
262
|
+
}
|
|
263
|
+
// A person who turned the sign-in task off keeps it off: only a preference that was never chosen (or was "on") goes back to "never chosen", so a later connect starts afresh.
|
|
264
|
+
if (readAutostartPreference(store.directory) !== false)
|
|
265
|
+
writeAutostartPreference(store.directory, undefined);
|
|
266
|
+
clearInstanceMarker(store.directory);
|
|
267
|
+
forgetRuntimeProfileNote(context.env, context.home, store.directory);
|
|
268
|
+
}
|
|
269
|
+
/**
|
|
270
|
+
* What the detached `run` process does around the normal Runtime: its output goes to the log, a stop request ends it the way Ctrl+C would, the launcher is told
|
|
271
|
+
* when AgEnD welcomed it (or that it failed, or that another Runtime already holds the profile) through the state file, and the marker `status` reads is kept while it runs.
|
|
272
|
+
*/
|
|
273
|
+
export async function runBackgroundInstance(context, store, body, runtimeVersion) {
|
|
274
|
+
const log = logFor(context, store), restore = captureProcessOutput(log);
|
|
275
|
+
// A crash prints its stack to a stderr nobody reads here; the log is where someone will look. The monitor only observes: Node still ends the process as it would.
|
|
276
|
+
const crashed = (error) => log.write(`The Runtime crashed: ${error.stack ?? error.message}`, "error");
|
|
277
|
+
process.on("uncaughtExceptionMonitor", crashed);
|
|
278
|
+
let stopAttempt, unwatch = () => { }, markerTimer, told = false;
|
|
279
|
+
const tell = (message) => { if (!told) {
|
|
280
|
+
told = true;
|
|
281
|
+
reportBackgroundState(store.directory, context.env, message);
|
|
282
|
+
} };
|
|
283
|
+
try {
|
|
284
|
+
const existing = await readRuntimeInstance(store, instanceDeps(context));
|
|
285
|
+
if (existing.state === "running" && existing.pid !== process.pid) {
|
|
286
|
+
process.stdout.write(`A Runtime already runs for this profile (process ${existing.pid}); this one did not start.\n`);
|
|
287
|
+
tell({ status: "already-running", ...(existing.pid ? { pid: existing.pid } : {}) });
|
|
288
|
+
return;
|
|
289
|
+
}
|
|
290
|
+
clearStopRequest(store.directory);
|
|
291
|
+
process.stdout.write(`AgEnD Runtime starting in the background (process ${process.pid}).\n`);
|
|
292
|
+
const finished = body.run(text => { process.stdout.write(`${text}\n`); if (text === RUNTIME_CONNECTED_REPORT)
|
|
293
|
+
tell({ status: "ready", pid: process.pid }); }, { onStopAttempt: attempt => { stopAttempt = attempt; } });
|
|
294
|
+
// Listeners for SIGINT/SIGTERM are in place once `run` has been called, so a stop request can end the Runtime the same way Ctrl+C does.
|
|
295
|
+
// The watch keeps going after an attempt: a shutdown that is not confirmed leaves the Runtime up, and the next `stop` / `restart` must be able to retry. One attempt at a time.
|
|
296
|
+
unwatch = watchStopRequest(store.directory, async () => {
|
|
297
|
+
process.stdout.write("Stop requested (agend-runtime stop); stopping.\n");
|
|
298
|
+
if (stopAttempt)
|
|
299
|
+
await stopAttempt();
|
|
300
|
+
else
|
|
301
|
+
process.emit("SIGTERM", "SIGTERM"); // the update controller's own handlers, when it runs the Runtime
|
|
302
|
+
}, context.seams.watchMs ?? 1000);
|
|
303
|
+
// The marker says "this PID is a background Runtime"; it is written only once this process holds the profile lock, so a second start that loses the race never claims it.
|
|
304
|
+
markerTimer = setInterval(() => { if (store.lockInfo()?.pid === process.pid) {
|
|
305
|
+
writeInstanceMarker(store.directory, process.pid, Date.now(), runtimeVersion);
|
|
306
|
+
if (markerTimer)
|
|
307
|
+
clearInterval(markerTimer);
|
|
308
|
+
markerTimer = undefined;
|
|
309
|
+
} }, 200);
|
|
310
|
+
markerTimer.unref();
|
|
311
|
+
await finished;
|
|
312
|
+
process.stdout.write("This AgEnD Runtime process ended (it was stopped, or handed over to an updated version).\n");
|
|
313
|
+
}
|
|
314
|
+
catch (error) {
|
|
315
|
+
if (error instanceof RuntimeProfileInUseError) {
|
|
316
|
+
process.stdout.write(`A Runtime already runs for this profile (process ${error.pid}); this one did not start.\n`);
|
|
317
|
+
tell({ status: "already-running", pid: error.pid });
|
|
318
|
+
}
|
|
319
|
+
else {
|
|
320
|
+
const message = error instanceof Error ? error.message : "The Runtime failed";
|
|
321
|
+
process.stderr.write(`${message}\n`);
|
|
322
|
+
process.exitCode = 1;
|
|
323
|
+
tell({ status: "failed", message });
|
|
324
|
+
}
|
|
325
|
+
}
|
|
326
|
+
finally {
|
|
327
|
+
unwatch();
|
|
328
|
+
if (markerTimer)
|
|
329
|
+
clearInterval(markerTimer);
|
|
330
|
+
process.off("uncaughtExceptionMonitor", crashed);
|
|
331
|
+
clearInstanceMarker(store.directory, process.pid);
|
|
332
|
+
restore();
|
|
333
|
+
}
|
|
334
|
+
}
|
|
335
|
+
export { RUNTIME_BACKGROUND_ENV };
|
|
336
|
+
//# sourceMappingURL=runtime-cli-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