The export is its own installer step, and the result names the operator files

This commit is contained in:
2026-09-21 01:11:52 +02:00
parent ee0c8b856e
commit 036af3cfdc
+6 -5
View File
@@ -64,6 +64,7 @@ const (
StepNetwork Step = "network"
StepFilter Step = "filter"
StepExtras Step = "extras"
StepExport Step = "export"
)
// Steps in the order they happen, so a failure can say "step 2 of 11".
@@ -84,7 +85,7 @@ var Steps = []Step{
// Phase two. The twelve above make a mesh that RUNS; these make one that WORKS — able to
// build, to say what it holds, on its network, filtering. They used to be things somebody
// typed afterwards, which is how they went missing without anything complaining.
StepBase, StepStore, StepBroker, StepVault, StepCatalogue, StepNetwork, StepFilter, StepExtras,
StepBase, StepStore, StepBroker, StepVault, StepCatalogue, StepNetwork, StepFilter, StepExtras, StepExport,
}
// Error is a failure, named by the step it happened in.
@@ -206,9 +207,9 @@ type Deps struct {
type Result struct {
// OperatorKey is where the operator's private key was written; OperatorKeyMade whether this
// run made it. RootExport is where the operator-sealed export landed.
OperatorKey string
OperatorKeyMade bool
RootExport string
OperatorKey string `json:"operator-key,omitempty"`
OperatorKeyMade bool `json:"operator-key-made,omitempty"`
RootExport string `json:"root-export,omitempty"`
System string `json:"system"`
DryRun bool `json:"dry-run,omitempty"`
@@ -686,7 +687,7 @@ func Run(ctx context.Context, o Options, d Deps, say func(string)) (Result, erro
exported, err := ExportRootSecrets(ctx, o, permanentControl, say)
result.RootExport = exported
if err != nil {
return result, failed(StepExtras, err)
return result, failed(StepExport, err)
}
say("\nthis machine is a mesh of one node: it builds its own software, holds its graph, " +