@forgezero/agent 0.1.62 → 0.1.64
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/README.md +45 -16
- package/dist/agent-heartbeat.js +1 -1
- package/dist/bootstrap-bundle.d.ts +31 -0
- package/dist/bootstrap-bundle.js +165 -0
- package/dist/bootstrap.d.ts +24 -18
- package/dist/bootstrap.js +509 -269
- package/dist/cli/agent-install.d.ts +2 -0
- package/dist/community-rehearsal-host.js +7 -5
- package/dist/definition.js +7 -5
- package/dist/deploy-file.js +7 -5
- package/dist/deployment.d.ts +27 -0
- package/dist/fz-agent.js +594 -421
- package/dist/fz.js +847 -372
- package/dist/metal-bootstrap.js +1 -1
- package/dist/metal-helper-socket.js +0 -2
- package/dist/metal-provision.js +0 -2
- package/dist/operator-bootstrap.d.ts +43 -1
- package/dist/operator-bootstrap.js +788 -367
- package/dist/platform-bootstrap-runtime.d.ts +0 -2
- package/dist/platform-bootstrap-runtime.js +0 -4
- package/dist/platform-fleet-verification.js +190 -98
- package/dist/provision.d.ts +4 -1
- package/dist/provision.js +41 -32
- package/dist/software-helper.js +7 -5
- package/dist/software.d.ts +1 -1
- package/dist/software.js +7 -5
- package/dist/version.d.ts +1 -1
- package/package.json +5 -1
|
@@ -31,7 +31,8 @@ var SOFTWARE_CATALOG = [
|
|
|
31
31
|
{ id: "cloudflared", version: "2026.7.3", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" },
|
|
32
32
|
{ id: "cloudflare-warp", version: "2026.6.822.0-min", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" },
|
|
33
33
|
{ id: "ufw", version: "ubuntu-26.04", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" },
|
|
34
|
-
{ id: "openssh-client", version: "ubuntu-26.04", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" }
|
|
34
|
+
{ id: "openssh-client", version: "ubuntu-26.04", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" },
|
|
35
|
+
{ id: "git", version: "ubuntu-26.04", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" }
|
|
35
36
|
];
|
|
36
37
|
var UBUNTU_2604_X64 = [
|
|
37
38
|
{ requirement: { id: "bun", version: "1.3.14" } },
|
|
@@ -41,7 +42,8 @@ var UBUNTU_2604_X64 = [
|
|
|
41
42
|
{ requirement: { id: "cloudflared", version: "2026.7.3" } },
|
|
42
43
|
{ requirement: { id: "cloudflare-warp", version: "2026.6.822.0-min" } },
|
|
43
44
|
{ requirement: { id: "ufw", version: "ubuntu-26.04" } },
|
|
44
|
-
{ requirement: { id: "openssh-client", version: "ubuntu-26.04" } }
|
|
45
|
+
{ requirement: { id: "openssh-client", version: "ubuntu-26.04" } },
|
|
46
|
+
{ requirement: { id: "git", version: "ubuntu-26.04" } }
|
|
45
47
|
];
|
|
46
48
|
var path = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin";
|
|
47
49
|
var DOCKER_DAEMON_PATH = "/etc/docker/daemon.json";
|
|
@@ -128,7 +130,7 @@ async function executeSoftwareOperation(operation) {
|
|
|
128
130
|
const supported = observed && observed.some((part, index) => part > minimum[index] && observed.slice(0, index).every((prior, priorIndex) => prior === minimum[priorIndex])) || observed?.every((part, index) => part === minimum[index]);
|
|
129
131
|
return { ...result, exitCode: result.exitCode === 0 && supported ? 0 : 1 };
|
|
130
132
|
});
|
|
131
|
-
const binaries = software === "ufw" ? ["/usr/sbin/ufw"] : ["/usr/bin/ssh", "/usr/bin/scp", "/usr/bin/ssh-keyscan", "/usr/bin/ssh-keygen"];
|
|
133
|
+
const binaries = software === "ufw" ? ["/usr/sbin/ufw"] : software === "git" ? ["/usr/bin/git"] : ["/usr/bin/ssh", "/usr/bin/scp", "/usr/bin/ssh-keyscan", "/usr/bin/ssh-keygen"];
|
|
132
134
|
try {
|
|
133
135
|
binaries.forEach((binary) => accessSync(binary));
|
|
134
136
|
return { exitCode: 0, output: "" };
|
|
@@ -136,7 +138,7 @@ async function executeSoftwareOperation(operation) {
|
|
|
136
138
|
return { exitCode: 1, output: cause instanceof Error ? cause.message : String(cause) };
|
|
137
139
|
}
|
|
138
140
|
}
|
|
139
|
-
if (software === "docker" || software === "nginx" || software === "ufw" || software === "openssh-client") {
|
|
141
|
+
if (software === "docker" || software === "nginx" || software === "ufw" || software === "openssh-client" || software === "git") {
|
|
140
142
|
const packageName = software === "openssh-client" ? "openssh-client" : software === "docker" ? "docker.io" : software;
|
|
141
143
|
const installed = await aptInstall(packageName);
|
|
142
144
|
if (installed.exitCode !== 0 || software !== "nginx" && software !== "docker")
|
|
@@ -236,7 +238,7 @@ function validateSoftwareRequirements(value, _options = {}) {
|
|
|
236
238
|
if (Object.keys(row).some((key) => key !== "id" && key !== "version")) {
|
|
237
239
|
throw new Error("software requirement contains an unknown field");
|
|
238
240
|
}
|
|
239
|
-
if (!["bun", "docker", "nginx", "arangodb", "cloudflared", "cloudflare-warp", "ufw", "openssh-client"].includes(String(row.id)) || typeof row.version !== "string" || !/^[A-Za-z0-9][A-Za-z0-9.-]{0,31}$/.test(row.version)) {
|
|
241
|
+
if (!["bun", "docker", "nginx", "arangodb", "cloudflared", "cloudflare-warp", "ufw", "openssh-client", "git"].includes(String(row.id)) || typeof row.version !== "string" || !/^[A-Za-z0-9][A-Za-z0-9.-]{0,31}$/.test(row.version)) {
|
|
240
242
|
throw new Error("software requirement coordinate is invalid");
|
|
241
243
|
}
|
|
242
244
|
const requirement = { id: row.id, version: row.version };
|
package/dist/definition.js
CHANGED
|
@@ -31,7 +31,8 @@ var SOFTWARE_CATALOG = [
|
|
|
31
31
|
{ id: "cloudflared", version: "2026.7.3", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" },
|
|
32
32
|
{ id: "cloudflare-warp", version: "2026.6.822.0-min", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" },
|
|
33
33
|
{ id: "ufw", version: "ubuntu-26.04", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" },
|
|
34
|
-
{ id: "openssh-client", version: "ubuntu-26.04", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" }
|
|
34
|
+
{ id: "openssh-client", version: "ubuntu-26.04", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" },
|
|
35
|
+
{ id: "git", version: "ubuntu-26.04", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" }
|
|
35
36
|
];
|
|
36
37
|
var UBUNTU_2604_X64 = [
|
|
37
38
|
{ requirement: { id: "bun", version: "1.3.14" } },
|
|
@@ -41,7 +42,8 @@ var UBUNTU_2604_X64 = [
|
|
|
41
42
|
{ requirement: { id: "cloudflared", version: "2026.7.3" } },
|
|
42
43
|
{ requirement: { id: "cloudflare-warp", version: "2026.6.822.0-min" } },
|
|
43
44
|
{ requirement: { id: "ufw", version: "ubuntu-26.04" } },
|
|
44
|
-
{ requirement: { id: "openssh-client", version: "ubuntu-26.04" } }
|
|
45
|
+
{ requirement: { id: "openssh-client", version: "ubuntu-26.04" } },
|
|
46
|
+
{ requirement: { id: "git", version: "ubuntu-26.04" } }
|
|
45
47
|
];
|
|
46
48
|
var path = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin";
|
|
47
49
|
var DOCKER_DAEMON_PATH = "/etc/docker/daemon.json";
|
|
@@ -128,7 +130,7 @@ async function executeSoftwareOperation(operation) {
|
|
|
128
130
|
const supported = observed && observed.some((part, index) => part > minimum[index] && observed.slice(0, index).every((prior, priorIndex) => prior === minimum[priorIndex])) || observed?.every((part, index) => part === minimum[index]);
|
|
129
131
|
return { ...result, exitCode: result.exitCode === 0 && supported ? 0 : 1 };
|
|
130
132
|
});
|
|
131
|
-
const binaries = software === "ufw" ? ["/usr/sbin/ufw"] : ["/usr/bin/ssh", "/usr/bin/scp", "/usr/bin/ssh-keyscan", "/usr/bin/ssh-keygen"];
|
|
133
|
+
const binaries = software === "ufw" ? ["/usr/sbin/ufw"] : software === "git" ? ["/usr/bin/git"] : ["/usr/bin/ssh", "/usr/bin/scp", "/usr/bin/ssh-keyscan", "/usr/bin/ssh-keygen"];
|
|
132
134
|
try {
|
|
133
135
|
binaries.forEach((binary) => accessSync(binary));
|
|
134
136
|
return { exitCode: 0, output: "" };
|
|
@@ -136,7 +138,7 @@ async function executeSoftwareOperation(operation) {
|
|
|
136
138
|
return { exitCode: 1, output: cause instanceof Error ? cause.message : String(cause) };
|
|
137
139
|
}
|
|
138
140
|
}
|
|
139
|
-
if (software === "docker" || software === "nginx" || software === "ufw" || software === "openssh-client") {
|
|
141
|
+
if (software === "docker" || software === "nginx" || software === "ufw" || software === "openssh-client" || software === "git") {
|
|
140
142
|
const packageName = software === "openssh-client" ? "openssh-client" : software === "docker" ? "docker.io" : software;
|
|
141
143
|
const installed = await aptInstall(packageName);
|
|
142
144
|
if (installed.exitCode !== 0 || software !== "nginx" && software !== "docker")
|
|
@@ -236,7 +238,7 @@ function validateSoftwareRequirements(value, _options = {}) {
|
|
|
236
238
|
if (Object.keys(row).some((key) => key !== "id" && key !== "version")) {
|
|
237
239
|
throw new Error("software requirement contains an unknown field");
|
|
238
240
|
}
|
|
239
|
-
if (!["bun", "docker", "nginx", "arangodb", "cloudflared", "cloudflare-warp", "ufw", "openssh-client"].includes(String(row.id)) || typeof row.version !== "string" || !/^[A-Za-z0-9][A-Za-z0-9.-]{0,31}$/.test(row.version)) {
|
|
241
|
+
if (!["bun", "docker", "nginx", "arangodb", "cloudflared", "cloudflare-warp", "ufw", "openssh-client", "git"].includes(String(row.id)) || typeof row.version !== "string" || !/^[A-Za-z0-9][A-Za-z0-9.-]{0,31}$/.test(row.version)) {
|
|
240
242
|
throw new Error("software requirement coordinate is invalid");
|
|
241
243
|
}
|
|
242
244
|
const requirement = { id: row.id, version: row.version };
|
package/dist/deploy-file.js
CHANGED
|
@@ -31,7 +31,8 @@ var SOFTWARE_CATALOG = [
|
|
|
31
31
|
{ id: "cloudflared", version: "2026.7.3", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" },
|
|
32
32
|
{ id: "cloudflare-warp", version: "2026.6.822.0-min", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" },
|
|
33
33
|
{ id: "ufw", version: "ubuntu-26.04", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" },
|
|
34
|
-
{ id: "openssh-client", version: "ubuntu-26.04", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" }
|
|
34
|
+
{ id: "openssh-client", version: "ubuntu-26.04", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" },
|
|
35
|
+
{ id: "git", version: "ubuntu-26.04", status: "active", os: "ubuntu", osVersion: "26.04", architecture: "x64", evidence: "reviewed-strategy-and-tests" }
|
|
35
36
|
];
|
|
36
37
|
var UBUNTU_2604_X64 = [
|
|
37
38
|
{ requirement: { id: "bun", version: "1.3.14" } },
|
|
@@ -41,7 +42,8 @@ var UBUNTU_2604_X64 = [
|
|
|
41
42
|
{ requirement: { id: "cloudflared", version: "2026.7.3" } },
|
|
42
43
|
{ requirement: { id: "cloudflare-warp", version: "2026.6.822.0-min" } },
|
|
43
44
|
{ requirement: { id: "ufw", version: "ubuntu-26.04" } },
|
|
44
|
-
{ requirement: { id: "openssh-client", version: "ubuntu-26.04" } }
|
|
45
|
+
{ requirement: { id: "openssh-client", version: "ubuntu-26.04" } },
|
|
46
|
+
{ requirement: { id: "git", version: "ubuntu-26.04" } }
|
|
45
47
|
];
|
|
46
48
|
var path = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin";
|
|
47
49
|
var DOCKER_DAEMON_PATH = "/etc/docker/daemon.json";
|
|
@@ -128,7 +130,7 @@ async function executeSoftwareOperation(operation) {
|
|
|
128
130
|
const supported = observed && observed.some((part, index) => part > minimum[index] && observed.slice(0, index).every((prior, priorIndex) => prior === minimum[priorIndex])) || observed?.every((part, index) => part === minimum[index]);
|
|
129
131
|
return { ...result, exitCode: result.exitCode === 0 && supported ? 0 : 1 };
|
|
130
132
|
});
|
|
131
|
-
const binaries = software === "ufw" ? ["/usr/sbin/ufw"] : ["/usr/bin/ssh", "/usr/bin/scp", "/usr/bin/ssh-keyscan", "/usr/bin/ssh-keygen"];
|
|
133
|
+
const binaries = software === "ufw" ? ["/usr/sbin/ufw"] : software === "git" ? ["/usr/bin/git"] : ["/usr/bin/ssh", "/usr/bin/scp", "/usr/bin/ssh-keyscan", "/usr/bin/ssh-keygen"];
|
|
132
134
|
try {
|
|
133
135
|
binaries.forEach((binary) => accessSync(binary));
|
|
134
136
|
return { exitCode: 0, output: "" };
|
|
@@ -136,7 +138,7 @@ async function executeSoftwareOperation(operation) {
|
|
|
136
138
|
return { exitCode: 1, output: cause instanceof Error ? cause.message : String(cause) };
|
|
137
139
|
}
|
|
138
140
|
}
|
|
139
|
-
if (software === "docker" || software === "nginx" || software === "ufw" || software === "openssh-client") {
|
|
141
|
+
if (software === "docker" || software === "nginx" || software === "ufw" || software === "openssh-client" || software === "git") {
|
|
140
142
|
const packageName = software === "openssh-client" ? "openssh-client" : software === "docker" ? "docker.io" : software;
|
|
141
143
|
const installed = await aptInstall(packageName);
|
|
142
144
|
if (installed.exitCode !== 0 || software !== "nginx" && software !== "docker")
|
|
@@ -236,7 +238,7 @@ function validateSoftwareRequirements(value, _options = {}) {
|
|
|
236
238
|
if (Object.keys(row).some((key) => key !== "id" && key !== "version")) {
|
|
237
239
|
throw new Error("software requirement contains an unknown field");
|
|
238
240
|
}
|
|
239
|
-
if (!["bun", "docker", "nginx", "arangodb", "cloudflared", "cloudflare-warp", "ufw", "openssh-client"].includes(String(row.id)) || typeof row.version !== "string" || !/^[A-Za-z0-9][A-Za-z0-9.-]{0,31}$/.test(row.version)) {
|
|
241
|
+
if (!["bun", "docker", "nginx", "arangodb", "cloudflared", "cloudflare-warp", "ufw", "openssh-client", "git"].includes(String(row.id)) || typeof row.version !== "string" || !/^[A-Za-z0-9][A-Za-z0-9.-]{0,31}$/.test(row.version)) {
|
|
240
242
|
throw new Error("software requirement coordinate is invalid");
|
|
241
243
|
}
|
|
242
244
|
const requirement = { id: row.id, version: row.version };
|
package/dist/deployment.d.ts
CHANGED
|
@@ -8,6 +8,7 @@ import { type RunResult } from './pipeline';
|
|
|
8
8
|
import type { SecretCache } from './cache';
|
|
9
9
|
import type { AttestationSource } from './socket';
|
|
10
10
|
import { type CapacityCalibration, type CapacityCalibrationOptions } from './capacity-calibration';
|
|
11
|
+
import { type BootstrapBundleManifest } from './bootstrap-bundle';
|
|
11
12
|
export interface CommandInput {
|
|
12
13
|
argv: readonly string[];
|
|
13
14
|
cwd?: string;
|
|
@@ -33,6 +34,8 @@ export interface DeploymentResult {
|
|
|
33
34
|
definitionDigest: string;
|
|
34
35
|
definitionVersion: number;
|
|
35
36
|
profile: string;
|
|
37
|
+
/** Resolved only from the validated plan and its bounded inputs at this revision. */
|
|
38
|
+
resolvedTargets?: readonly ResolvedDeploymentTarget[];
|
|
36
39
|
release: string;
|
|
37
40
|
ok: boolean;
|
|
38
41
|
phases: readonly RunResult[];
|
|
@@ -43,6 +46,15 @@ export interface DeploymentResult {
|
|
|
43
46
|
};
|
|
44
47
|
};
|
|
45
48
|
}
|
|
49
|
+
export interface ResolvedDeploymentTarget {
|
|
50
|
+
name: string;
|
|
51
|
+
profiles: readonly string[];
|
|
52
|
+
confidentialCompute: 'required' | 'preferred' | 'disabled';
|
|
53
|
+
labels: Readonly<Record<string, string>>;
|
|
54
|
+
minimum: number;
|
|
55
|
+
desired: number;
|
|
56
|
+
maximum: number;
|
|
57
|
+
}
|
|
46
58
|
/**
|
|
47
59
|
* How the credential-bearing agent may read one server-owned Git source.
|
|
48
60
|
* Secret values never appear in a deployment claim or checked-in pipeline.
|
|
@@ -55,12 +67,27 @@ export type GitSourceAuth = {
|
|
|
55
67
|
kind: 'vault-token';
|
|
56
68
|
secret: string;
|
|
57
69
|
username?: string;
|
|
70
|
+
}
|
|
71
|
+
/** One-claim credential delivered only inside the hybrid-sealed node response. */
|
|
72
|
+
| {
|
|
73
|
+
kind: 'ephemeral-token';
|
|
74
|
+
token: string;
|
|
75
|
+
expiresAtTs: number;
|
|
76
|
+
username?: string;
|
|
58
77
|
};
|
|
59
78
|
export interface DeploymentOptions {
|
|
60
79
|
/** Queue key. The same deployment target is serial; different targets may run in parallel. */
|
|
61
80
|
key: string;
|
|
62
81
|
repository: string;
|
|
63
82
|
branch: string;
|
|
83
|
+
/**
|
|
84
|
+
* Release-generation-one source copied by the attended operator. It is a
|
|
85
|
+
* local Git bundle, never a network credential or a persistent CI source.
|
|
86
|
+
*/
|
|
87
|
+
bootstrapBundle?: {
|
|
88
|
+
path: string;
|
|
89
|
+
manifest: BootstrapBundleManifest;
|
|
90
|
+
};
|
|
64
91
|
profile: string;
|
|
65
92
|
root: string;
|
|
66
93
|
publicApiUrl?: string;
|