@forgezero/agent 0.1.115 → 0.1.116
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/agent-heartbeat.js +1 -1
- package/dist/bootstrap.js +4 -1
- package/dist/fz-agent.js +1 -1
- package/dist/fz.js +26 -10
- package/dist/metal-bootstrap.js +1 -1
- package/dist/operator-bootstrap.d.ts +1 -1
- package/dist/operator-bootstrap.js +8 -5
- package/dist/platform-bootstrap-runtime.js +3 -0
- package/dist/platform-fleet-verification.js +4 -1
- package/dist/platform-genesis.d.ts +2 -0
- package/dist/platform-genesis.js +4 -0
- package/dist/provision.js +1 -1
- package/dist/version.d.ts +1 -1
- package/package.json +1 -1
package/dist/agent-heartbeat.js
CHANGED
package/dist/bootstrap.js
CHANGED
|
@@ -1460,7 +1460,7 @@ var UPDATE_RETRY_BASE_MS = 5 * 60000;
|
|
|
1460
1460
|
var UPDATE_RETRY_MAX_MS = 24 * 60 * 60000;
|
|
1461
1461
|
|
|
1462
1462
|
// src/version.ts
|
|
1463
|
-
var VERSION = "0.1.
|
|
1463
|
+
var VERSION = "0.1.116";
|
|
1464
1464
|
|
|
1465
1465
|
// src/software.ts
|
|
1466
1466
|
var PINNED_BUN_VERSION = "1.3.14";
|
|
@@ -3127,6 +3127,9 @@ function platformGenesisClaims(guests, sshPublicKeys) {
|
|
|
3127
3127
|
throw new Error("platform genesis requires at least one operator SSH public key");
|
|
3128
3128
|
return reviewed.map((guest) => claimFor(guest, keys, "create"));
|
|
3129
3129
|
}
|
|
3130
|
+
function platformGenesisDeletionClaims(guests) {
|
|
3131
|
+
return validatePlatformGenesisGuests(guests).map((guest) => claimFor(guest, [], "delete"));
|
|
3132
|
+
}
|
|
3130
3133
|
function platformCommunityRehearsalClaims(seedGuests, rehearsalGuest, sshPublicKeys) {
|
|
3131
3134
|
const reviewed = validatePlatformGenesisGuests([...seedGuests, rehearsalGuest], 4);
|
|
3132
3135
|
const keys = [...new Set(sshPublicKeys.map(publicKey))];
|
package/dist/fz-agent.js
CHANGED
package/dist/fz.js
CHANGED
|
@@ -4841,7 +4841,7 @@ var UPDATE_RETRY_BASE_MS = 5 * 60000;
|
|
|
4841
4841
|
var UPDATE_RETRY_MAX_MS = 24 * 60 * 60000;
|
|
4842
4842
|
|
|
4843
4843
|
// src/version.ts
|
|
4844
|
-
var VERSION2 = "0.1.
|
|
4844
|
+
var VERSION2 = "0.1.116";
|
|
4845
4845
|
|
|
4846
4846
|
// src/software.ts
|
|
4847
4847
|
var PINNED_BUN_VERSION = "1.3.14";
|
|
@@ -12238,6 +12238,9 @@ function platformGenesisClaims(guests, sshPublicKeys) {
|
|
|
12238
12238
|
throw new Error("platform genesis requires at least one operator SSH public key");
|
|
12239
12239
|
return reviewed.map((guest) => claimFor(guest, keys, "create"));
|
|
12240
12240
|
}
|
|
12241
|
+
function platformGenesisDeletionClaims(guests) {
|
|
12242
|
+
return validatePlatformGenesisGuests(guests).map((guest) => claimFor(guest, [], "delete"));
|
|
12243
|
+
}
|
|
12241
12244
|
function platformCommunityRehearsalClaims(seedGuests, rehearsalGuest, sshPublicKeys) {
|
|
12242
12245
|
const reviewed = validatePlatformGenesisGuests([...seedGuests, rehearsalGuest], 4);
|
|
12243
12246
|
const keys = [...new Set(sshPublicKeys.map(publicKey))];
|
|
@@ -17363,14 +17366,14 @@ function planOperatorMetalBootstrap(request, mode) {
|
|
|
17363
17366
|
if ((mode === "rehearsal" || mode === "rehearsal-cleanup") && !request.genesis.rehearsalNode) {
|
|
17364
17367
|
throw new Error("the reviewed metal request has no rehearsal node");
|
|
17365
17368
|
}
|
|
17366
|
-
const claims = mode === "rehearsal" || mode === "rehearsal-cleanup" ? mode === "rehearsal-cleanup" ? platformCommunityRehearsalDeletionClaims(request.genesis.nodes, request.genesis.rehearsalNode) : platformCommunityRehearsalClaims(request.genesis.nodes, request.genesis.rehearsalNode, keys) : platformGenesisClaims(request.genesis.nodes, keys);
|
|
17369
|
+
const claims = mode === "genesis-cleanup" ? platformGenesisDeletionClaims(request.genesis.nodes) : mode === "rehearsal" || mode === "rehearsal-cleanup" ? mode === "rehearsal-cleanup" ? platformCommunityRehearsalDeletionClaims(request.genesis.nodes, request.genesis.rehearsalNode) : platformCommunityRehearsalClaims(request.genesis.nodes, request.genesis.rehearsalNode, keys) : platformGenesisClaims(request.genesis.nodes, keys);
|
|
17367
17370
|
const genesisNodes = mode === "host-keys" ? request.genesis.nodes.map(({ name }) => name) : mode === "rehearsal-host-keys" ? guestRows(request).map(({ name }) => name) : claims.map((claim) => claim.spec.guestName).filter((name) => Boolean(name));
|
|
17368
17371
|
return {
|
|
17369
17372
|
kind: "metal-remote",
|
|
17370
17373
|
mode,
|
|
17371
17374
|
mutation: !["status", "host-keys", "rehearsal-host-keys"].includes(mode),
|
|
17372
17375
|
target: { address: request.target.address, port: request.target.port, user: request.target.user },
|
|
17373
|
-
steps: mode === "status" ? ["verify pinned SSH transport", "run typed fz bootstrap status"] : mode === "host-keys" || mode === "rehearsal-host-keys" ? ["verify pinned SSH transport", "collect exact Ed25519 host keys for the reviewed guest addresses"] : mode === "genesis" || mode === "rehearsal" || mode === "rehearsal-cleanup" ? ["verify pinned SSH transport", mode === "rehearsal" ? "send the three reviewed seed claims plus the reviewed fourth Community rehearsal claim to the constrained Metal helper" : mode === "rehearsal-cleanup" ? "delete the exact four reviewed disposable guests and their owned disks, units, seed data and inventory" : "send the three reviewed platform-genesis claims to the constrained Metal helper"] : [
|
|
17376
|
+
steps: mode === "status" ? ["verify pinned SSH transport", "run typed fz bootstrap status"] : mode === "host-keys" || mode === "rehearsal-host-keys" ? ["verify pinned SSH transport", "collect exact Ed25519 host keys for the reviewed guest addresses"] : mode === "genesis" || mode === "genesis-cleanup" || mode === "rehearsal" || mode === "rehearsal-cleanup" ? ["verify pinned SSH transport", mode === "rehearsal" ? "send the three reviewed seed claims plus the reviewed fourth Community rehearsal claim to the constrained Metal helper" : mode === "genesis-cleanup" ? "delete the exact three reviewed platform guests and their owned disks, units, seed data and inventory" : mode === "rehearsal-cleanup" ? "delete the exact four reviewed disposable guests and their owned disks, units, seed data and inventory" : "send the three reviewed platform-genesis claims to the constrained Metal helper"] : [
|
|
17374
17377
|
"verify pinned SSH transport and caller-approved SSH agent",
|
|
17375
17378
|
"copy pinned Bun and packaged fz artifacts to private staging",
|
|
17376
17379
|
"stage the strict owner-only metal config and optional seed handoff",
|
|
@@ -17968,13 +17971,13 @@ async function applyOperatorMetalBootstrap(request, mode, options = {}) {
|
|
|
17968
17971
|
output: JSON.stringify(await collectOperatorGuestHostKeys(request, { ...options, exec }, mode === "rehearsal-host-keys"))
|
|
17969
17972
|
};
|
|
17970
17973
|
}
|
|
17971
|
-
if (mode === "genesis" || mode === "rehearsal" || mode === "rehearsal-cleanup") {
|
|
17974
|
+
if (mode === "genesis" || mode === "genesis-cleanup" || mode === "rehearsal" || mode === "rehearsal-cleanup") {
|
|
17972
17975
|
const keys = request.genesis.sshPublicKeyFiles.map((path) => publicIdentity(path));
|
|
17973
17976
|
if ((mode === "rehearsal" || mode === "rehearsal-cleanup") && !request.genesis.rehearsalNode) {
|
|
17974
17977
|
throw new Error("the reviewed metal request has no rehearsal node");
|
|
17975
17978
|
}
|
|
17976
17979
|
const outputs = [];
|
|
17977
|
-
const claims = mode === "rehearsal" || mode === "rehearsal-cleanup" ? mode === "rehearsal-cleanup" ? platformCommunityRehearsalDeletionClaims(request.genesis.nodes, request.genesis.rehearsalNode) : platformCommunityRehearsalClaims(request.genesis.nodes, request.genesis.rehearsalNode, keys) : platformGenesisClaims(request.genesis.nodes, keys);
|
|
17980
|
+
const claims = mode === "genesis-cleanup" ? platformGenesisDeletionClaims(request.genesis.nodes) : mode === "rehearsal" || mode === "rehearsal-cleanup" ? mode === "rehearsal-cleanup" ? platformCommunityRehearsalDeletionClaims(request.genesis.nodes, request.genesis.rehearsalNode) : platformCommunityRehearsalClaims(request.genesis.nodes, request.genesis.rehearsalNode, keys) : platformGenesisClaims(request.genesis.nodes, keys);
|
|
17978
17981
|
for (const claim of claims) {
|
|
17979
17982
|
outputs.push(await remote(exec, request, knownHosts, ["/usr/bin/sudo", "-n", "/usr/local/bin/fz-agent", "metal-apply", "--claim=-"], `provision ${claim.spec.guestName}`, false, `${JSON.stringify(claim)}
|
|
17980
17983
|
`));
|
|
@@ -18878,7 +18881,9 @@ function parseOptions(argv2) {
|
|
|
18878
18881
|
options.bootstrapConfigPath = argv2[++index];
|
|
18879
18882
|
else if (token === "--secrets-env-file")
|
|
18880
18883
|
options.bootstrapSecretsEnvFile = argv2[++index];
|
|
18881
|
-
else if (token
|
|
18884
|
+
else if (token.startsWith("--confirm-disposable-fleet=")) {
|
|
18885
|
+
options.disposableFleetConfirmation = token.slice("--confirm-disposable-fleet=".length);
|
|
18886
|
+
} else if (token === "--output")
|
|
18882
18887
|
options.outputPath = argv2[++index];
|
|
18883
18888
|
else if (token === "--query")
|
|
18884
18889
|
options.queries.push(argv2[++index] ?? "");
|
|
@@ -20075,8 +20080,8 @@ async function cmdBootstrap(options, args) {
|
|
|
20075
20080
|
}
|
|
20076
20081
|
if (operation === "metal" && args[1] === "remote") {
|
|
20077
20082
|
const mode = args[2];
|
|
20078
|
-
if (!mode || !["apply", "genesis", "rehearsal", "rehearsal-cleanup", "host-keys", "rehearsal-host-keys", "status"].includes(mode) || args[3] !== undefined) {
|
|
20079
|
-
throw new Error("Usage: fz bootstrap metal remote <apply|genesis|rehearsal|rehearsal-cleanup|host-keys|rehearsal-host-keys|status> --bootstrap-config <owner-only-request.json> [--output <owner-only-evidence.json>] [--apply]");
|
|
20083
|
+
if (!mode || !["apply", "genesis", "genesis-cleanup", "rehearsal", "rehearsal-cleanup", "host-keys", "rehearsal-host-keys", "status"].includes(mode) || args[3] !== undefined) {
|
|
20084
|
+
throw new Error("Usage: fz bootstrap metal remote <apply|genesis|genesis-cleanup|rehearsal|rehearsal-cleanup|host-keys|rehearsal-host-keys|status> --bootstrap-config <owner-only-request.json> [--output <owner-only-evidence.json>] [--confirm-disposable-fleet=<exact-names>] [--apply]");
|
|
20080
20085
|
}
|
|
20081
20086
|
if (!options.bootstrapConfigPath)
|
|
20082
20087
|
throw new Error("remote metal bootstrap requires --bootstrap-config");
|
|
@@ -20087,6 +20092,17 @@ async function cmdBootstrap(options, args) {
|
|
|
20087
20092
|
validateMetalConfig: mode === "apply"
|
|
20088
20093
|
});
|
|
20089
20094
|
const plan2 = planOperatorMetalBootstrap(request, mode);
|
|
20095
|
+
if (mode === "genesis-cleanup") {
|
|
20096
|
+
const expected = plan2.genesisNodes.join(",");
|
|
20097
|
+
if (!options.apply) {
|
|
20098
|
+
out.line(JSON.stringify({ ...plan2, requiredConfirmation: expected }, null, 2));
|
|
20099
|
+
out.step(`Repeat with --confirm-disposable-fleet=${expected} --apply to delete only this reviewed fleet.`);
|
|
20100
|
+
return 0;
|
|
20101
|
+
}
|
|
20102
|
+
if (options.disposableFleetConfirmation !== expected) {
|
|
20103
|
+
throw new Error(`genesis cleanup requires --confirm-disposable-fleet=${expected}`);
|
|
20104
|
+
}
|
|
20105
|
+
}
|
|
20090
20106
|
if (!options.apply) {
|
|
20091
20107
|
out.line(JSON.stringify(plan2, null, 2));
|
|
20092
20108
|
out.step("Review the pinned metal target and exact genesis nodes, then repeat with --apply to contact the host.");
|
|
@@ -20188,7 +20204,7 @@ async function cmdBootstrap(options, args) {
|
|
|
20188
20204
|
return 0;
|
|
20189
20205
|
}
|
|
20190
20206
|
if (!["platform", "repair"].includes(operation)) {
|
|
20191
|
-
throw new Error("Usage: fz bootstrap config <metal|platform|cloudflare>|platform [launch|bundle|fleet <apply|status>|remote <apply|status>|cloudflare [verify|finalize]]|metal [remote <apply|genesis|rehearsal|rehearsal-cleanup|host-keys|rehearsal-host-keys|status>]|status|repair [--bootstrap-config <path>] [--apply]");
|
|
20207
|
+
throw new Error("Usage: fz bootstrap config <metal|platform|cloudflare>|platform [launch|bundle|fleet <apply|status>|remote <apply|status>|cloudflare [verify|finalize]]|metal [remote <apply|genesis|genesis-cleanup|rehearsal|rehearsal-cleanup|host-keys|rehearsal-host-keys|status>]|status|repair [--bootstrap-config <path>] [--apply]");
|
|
20192
20208
|
}
|
|
20193
20209
|
const config = options.bootstrapConfigPath ? readBootstrapConfig(options.bootstrapConfigPath) : operation === "repair" ? (() => {
|
|
20194
20210
|
throw new Error("repair requires --bootstrap-config so immutable coordinates are revalidated");
|
|
@@ -20858,7 +20874,7 @@ function usage() {
|
|
|
20858
20874
|
Persist secret-free public-node acceptance, then remove
|
|
20859
20875
|
the completed non-secret checkpoint and node handoffs
|
|
20860
20876
|
fz bootstrap metal Plan/install an identity-only physical provisioner
|
|
20861
|
-
fz bootstrap metal remote <apply|genesis|rehearsal|rehearsal-cleanup|host-keys|rehearsal-host-keys|status>
|
|
20877
|
+
fz bootstrap metal remote <apply|genesis|genesis-cleanup|rehearsal|rehearsal-cleanup|host-keys|rehearsal-host-keys|status>
|
|
20862
20878
|
Install/bootstrap one pinned blank metal target, then
|
|
20863
20879
|
provision the exact selected three-node genesis seed
|
|
20864
20880
|
fz bootstrap status Verify persisted profile and supervised units
|
package/dist/metal-bootstrap.js
CHANGED
|
@@ -366,7 +366,7 @@ function systemdAgentEgressDirectives(loopbackTcpPorts = []) {
|
|
|
366
366
|
}
|
|
367
367
|
|
|
368
368
|
// src/version.ts
|
|
369
|
-
var VERSION = "0.1.
|
|
369
|
+
var VERSION = "0.1.116";
|
|
370
370
|
|
|
371
371
|
// src/otel-collector.ts
|
|
372
372
|
var FORGEZERO_OTEL_COLLECTOR_UNIT = "forgezero-otel-collector.service";
|
|
@@ -90,7 +90,7 @@ export interface OperatorPlatformFleetCoordinates {
|
|
|
90
90
|
}[];
|
|
91
91
|
}
|
|
92
92
|
export type OperatorPlatformBootstrapMode = 'apply' | 'status';
|
|
93
|
-
export type OperatorMetalBootstrapMode = 'apply' | 'genesis' | 'rehearsal' | 'rehearsal-cleanup' | 'host-keys' | 'rehearsal-host-keys' | 'status';
|
|
93
|
+
export type OperatorMetalBootstrapMode = 'apply' | 'genesis' | 'genesis-cleanup' | 'rehearsal' | 'rehearsal-cleanup' | 'host-keys' | 'rehearsal-host-keys' | 'status';
|
|
94
94
|
export interface OperatorPlatformBootstrapPlan {
|
|
95
95
|
kind: 'platform-remote';
|
|
96
96
|
mode: OperatorPlatformBootstrapMode;
|
|
@@ -1460,7 +1460,7 @@ var UPDATE_RETRY_BASE_MS = 5 * 60000;
|
|
|
1460
1460
|
var UPDATE_RETRY_MAX_MS = 24 * 60 * 60000;
|
|
1461
1461
|
|
|
1462
1462
|
// src/version.ts
|
|
1463
|
-
var VERSION = "0.1.
|
|
1463
|
+
var VERSION = "0.1.116";
|
|
1464
1464
|
|
|
1465
1465
|
// src/software.ts
|
|
1466
1466
|
var PINNED_BUN_VERSION = "1.3.14";
|
|
@@ -3127,6 +3127,9 @@ function platformGenesisClaims(guests, sshPublicKeys) {
|
|
|
3127
3127
|
throw new Error("platform genesis requires at least one operator SSH public key");
|
|
3128
3128
|
return reviewed.map((guest) => claimFor(guest, keys, "create"));
|
|
3129
3129
|
}
|
|
3130
|
+
function platformGenesisDeletionClaims(guests) {
|
|
3131
|
+
return validatePlatformGenesisGuests(guests).map((guest) => claimFor(guest, [], "delete"));
|
|
3132
|
+
}
|
|
3130
3133
|
function platformCommunityRehearsalClaims(seedGuests, rehearsalGuest, sshPublicKeys) {
|
|
3131
3134
|
const reviewed = validatePlatformGenesisGuests([...seedGuests, rehearsalGuest], 4);
|
|
3132
3135
|
const keys = [...new Set(sshPublicKeys.map(publicKey))];
|
|
@@ -6712,14 +6715,14 @@ function planOperatorMetalBootstrap(request, mode) {
|
|
|
6712
6715
|
if ((mode === "rehearsal" || mode === "rehearsal-cleanup") && !request.genesis.rehearsalNode) {
|
|
6713
6716
|
throw new Error("the reviewed metal request has no rehearsal node");
|
|
6714
6717
|
}
|
|
6715
|
-
const claims = mode === "rehearsal" || mode === "rehearsal-cleanup" ? mode === "rehearsal-cleanup" ? platformCommunityRehearsalDeletionClaims(request.genesis.nodes, request.genesis.rehearsalNode) : platformCommunityRehearsalClaims(request.genesis.nodes, request.genesis.rehearsalNode, keys) : platformGenesisClaims(request.genesis.nodes, keys);
|
|
6718
|
+
const claims = mode === "genesis-cleanup" ? platformGenesisDeletionClaims(request.genesis.nodes) : mode === "rehearsal" || mode === "rehearsal-cleanup" ? mode === "rehearsal-cleanup" ? platformCommunityRehearsalDeletionClaims(request.genesis.nodes, request.genesis.rehearsalNode) : platformCommunityRehearsalClaims(request.genesis.nodes, request.genesis.rehearsalNode, keys) : platformGenesisClaims(request.genesis.nodes, keys);
|
|
6716
6719
|
const genesisNodes = mode === "host-keys" ? request.genesis.nodes.map(({ name }) => name) : mode === "rehearsal-host-keys" ? guestRows(request).map(({ name }) => name) : claims.map((claim) => claim.spec.guestName).filter((name) => Boolean(name));
|
|
6717
6720
|
return {
|
|
6718
6721
|
kind: "metal-remote",
|
|
6719
6722
|
mode,
|
|
6720
6723
|
mutation: !["status", "host-keys", "rehearsal-host-keys"].includes(mode),
|
|
6721
6724
|
target: { address: request.target.address, port: request.target.port, user: request.target.user },
|
|
6722
|
-
steps: mode === "status" ? ["verify pinned SSH transport", "run typed fz bootstrap status"] : mode === "host-keys" || mode === "rehearsal-host-keys" ? ["verify pinned SSH transport", "collect exact Ed25519 host keys for the reviewed guest addresses"] : mode === "genesis" || mode === "rehearsal" || mode === "rehearsal-cleanup" ? ["verify pinned SSH transport", mode === "rehearsal" ? "send the three reviewed seed claims plus the reviewed fourth Community rehearsal claim to the constrained Metal helper" : mode === "rehearsal-cleanup" ? "delete the exact four reviewed disposable guests and their owned disks, units, seed data and inventory" : "send the three reviewed platform-genesis claims to the constrained Metal helper"] : [
|
|
6725
|
+
steps: mode === "status" ? ["verify pinned SSH transport", "run typed fz bootstrap status"] : mode === "host-keys" || mode === "rehearsal-host-keys" ? ["verify pinned SSH transport", "collect exact Ed25519 host keys for the reviewed guest addresses"] : mode === "genesis" || mode === "genesis-cleanup" || mode === "rehearsal" || mode === "rehearsal-cleanup" ? ["verify pinned SSH transport", mode === "rehearsal" ? "send the three reviewed seed claims plus the reviewed fourth Community rehearsal claim to the constrained Metal helper" : mode === "genesis-cleanup" ? "delete the exact three reviewed platform guests and their owned disks, units, seed data and inventory" : mode === "rehearsal-cleanup" ? "delete the exact four reviewed disposable guests and their owned disks, units, seed data and inventory" : "send the three reviewed platform-genesis claims to the constrained Metal helper"] : [
|
|
6723
6726
|
"verify pinned SSH transport and caller-approved SSH agent",
|
|
6724
6727
|
"copy pinned Bun and packaged fz artifacts to private staging",
|
|
6725
6728
|
"stage the strict owner-only metal config and optional seed handoff",
|
|
@@ -7412,13 +7415,13 @@ async function applyOperatorMetalBootstrap(request, mode, options = {}) {
|
|
|
7412
7415
|
output: JSON.stringify(await collectOperatorGuestHostKeys(request, { ...options, exec }, mode === "rehearsal-host-keys"))
|
|
7413
7416
|
};
|
|
7414
7417
|
}
|
|
7415
|
-
if (mode === "genesis" || mode === "rehearsal" || mode === "rehearsal-cleanup") {
|
|
7418
|
+
if (mode === "genesis" || mode === "genesis-cleanup" || mode === "rehearsal" || mode === "rehearsal-cleanup") {
|
|
7416
7419
|
const keys = request.genesis.sshPublicKeyFiles.map((path) => publicIdentity(path));
|
|
7417
7420
|
if ((mode === "rehearsal" || mode === "rehearsal-cleanup") && !request.genesis.rehearsalNode) {
|
|
7418
7421
|
throw new Error("the reviewed metal request has no rehearsal node");
|
|
7419
7422
|
}
|
|
7420
7423
|
const outputs = [];
|
|
7421
|
-
const claims = mode === "rehearsal" || mode === "rehearsal-cleanup" ? mode === "rehearsal-cleanup" ? platformCommunityRehearsalDeletionClaims(request.genesis.nodes, request.genesis.rehearsalNode) : platformCommunityRehearsalClaims(request.genesis.nodes, request.genesis.rehearsalNode, keys) : platformGenesisClaims(request.genesis.nodes, keys);
|
|
7424
|
+
const claims = mode === "genesis-cleanup" ? platformGenesisDeletionClaims(request.genesis.nodes) : mode === "rehearsal" || mode === "rehearsal-cleanup" ? mode === "rehearsal-cleanup" ? platformCommunityRehearsalDeletionClaims(request.genesis.nodes, request.genesis.rehearsalNode) : platformCommunityRehearsalClaims(request.genesis.nodes, request.genesis.rehearsalNode, keys) : platformGenesisClaims(request.genesis.nodes, keys);
|
|
7422
7425
|
for (const claim of claims) {
|
|
7423
7426
|
outputs.push(await remote(exec, request, knownHosts, ["/usr/bin/sudo", "-n", "/usr/local/bin/fz-agent", "metal-apply", "--claim=-"], `provision ${claim.spec.guestName}`, false, `${JSON.stringify(claim)}
|
|
7424
7427
|
`));
|
|
@@ -669,6 +669,9 @@ function platformGenesisClaims(guests, sshPublicKeys) {
|
|
|
669
669
|
throw new Error("platform genesis requires at least one operator SSH public key");
|
|
670
670
|
return reviewed.map((guest) => claimFor(guest, keys, "create"));
|
|
671
671
|
}
|
|
672
|
+
function platformGenesisDeletionClaims(guests) {
|
|
673
|
+
return validatePlatformGenesisGuests(guests).map((guest) => claimFor(guest, [], "delete"));
|
|
674
|
+
}
|
|
672
675
|
function platformCommunityRehearsalClaims(seedGuests, rehearsalGuest, sshPublicKeys) {
|
|
673
676
|
const reviewed = validatePlatformGenesisGuests([...seedGuests, rehearsalGuest], 4);
|
|
674
677
|
const keys = [...new Set(sshPublicKeys.map(publicKey))];
|
|
@@ -3009,7 +3009,7 @@ function requestSoftware(requirements, socketPath = DEFAULT_SOFTWARE_HELPER_SOCK
|
|
|
3009
3009
|
}
|
|
3010
3010
|
|
|
3011
3011
|
// src/version.ts
|
|
3012
|
-
var VERSION3 = "0.1.
|
|
3012
|
+
var VERSION3 = "0.1.116";
|
|
3013
3013
|
|
|
3014
3014
|
// src/egress-policy.ts
|
|
3015
3015
|
import { realpathSync as realpathSync3 } from "node:fs";
|
|
@@ -4185,6 +4185,9 @@ function platformGenesisClaims(guests, sshPublicKeys) {
|
|
|
4185
4185
|
throw new Error("platform genesis requires at least one operator SSH public key");
|
|
4186
4186
|
return reviewed.map((guest) => claimFor(guest, keys, "create"));
|
|
4187
4187
|
}
|
|
4188
|
+
function platformGenesisDeletionClaims(guests) {
|
|
4189
|
+
return validatePlatformGenesisGuests(guests).map((guest) => claimFor(guest, [], "delete"));
|
|
4190
|
+
}
|
|
4188
4191
|
function platformCommunityRehearsalClaims(seedGuests, rehearsalGuest, sshPublicKeys) {
|
|
4189
4192
|
const reviewed = validatePlatformGenesisGuests([...seedGuests, rehearsalGuest], 4);
|
|
4190
4193
|
const keys = [...new Set(sshPublicKeys.map(publicKey))];
|
|
@@ -21,6 +21,8 @@ export interface PlatformGenesisGuest {
|
|
|
21
21
|
export declare function validatePlatformGenesisGuests(guests: readonly PlatformGenesisGuest[], expectedCount?: number): readonly PlatformGenesisGuest[];
|
|
22
22
|
/** Convert reviewed desired state into the ordinary Metal provisioning claim. */
|
|
23
23
|
export declare function platformGenesisClaims(guests: readonly PlatformGenesisGuest[], sshPublicKeys: readonly string[]): readonly RemoteProvisionClaim[];
|
|
24
|
+
/** Exact inverse of the reviewed three-node platform seed. */
|
|
25
|
+
export declare function platformGenesisDeletionClaims(guests: readonly PlatformGenesisGuest[]): readonly RemoteProvisionClaim[];
|
|
24
26
|
/** Add one explicitly reviewed disposable node to the same three guest requests. */
|
|
25
27
|
export declare function platformCommunityRehearsalClaims(seedGuests: readonly PlatformGenesisGuest[], rehearsalGuest: PlatformGenesisGuest, sshPublicKeys: readonly string[]): readonly RemoteProvisionClaim[];
|
|
26
28
|
/** Exact inverse of the reviewed disposable four-host request. */
|
package/dist/platform-genesis.js
CHANGED
|
@@ -669,6 +669,9 @@ function platformGenesisClaims(guests, sshPublicKeys) {
|
|
|
669
669
|
throw new Error("platform genesis requires at least one operator SSH public key");
|
|
670
670
|
return reviewed.map((guest) => claimFor(guest, keys, "create"));
|
|
671
671
|
}
|
|
672
|
+
function platformGenesisDeletionClaims(guests) {
|
|
673
|
+
return validatePlatformGenesisGuests(guests).map((guest) => claimFor(guest, [], "delete"));
|
|
674
|
+
}
|
|
672
675
|
function platformCommunityRehearsalClaims(seedGuests, rehearsalGuest, sshPublicKeys) {
|
|
673
676
|
const reviewed = validatePlatformGenesisGuests([...seedGuests, rehearsalGuest], 4);
|
|
674
677
|
const keys = [...new Set(sshPublicKeys.map(publicKey))];
|
|
@@ -681,6 +684,7 @@ function platformCommunityRehearsalDeletionClaims(seedGuests, rehearsalGuest) {
|
|
|
681
684
|
}
|
|
682
685
|
export {
|
|
683
686
|
validatePlatformGenesisGuests,
|
|
687
|
+
platformGenesisDeletionClaims,
|
|
684
688
|
platformGenesisClaims,
|
|
685
689
|
platformCommunityRehearsalDeletionClaims,
|
|
686
690
|
platformCommunityRehearsalClaims
|
package/dist/provision.js
CHANGED
|
@@ -3009,7 +3009,7 @@ function requestSoftware(requirements, socketPath = DEFAULT_SOFTWARE_HELPER_SOCK
|
|
|
3009
3009
|
}
|
|
3010
3010
|
|
|
3011
3011
|
// src/version.ts
|
|
3012
|
-
var VERSION3 = "0.1.
|
|
3012
|
+
var VERSION3 = "0.1.116";
|
|
3013
3013
|
|
|
3014
3014
|
// src/egress-policy.ts
|
|
3015
3015
|
import { realpathSync as realpathSync3 } from "node:fs";
|
package/dist/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/** One package version shared by both public binaries. Pinned to package.json by tests. */
|
|
2
|
-
export declare const VERSION = "0.1.
|
|
2
|
+
export declare const VERSION = "0.1.116";
|