Ask build-agent for itself and its toolchain images, never a builder key (ADR 0520, issue 1851)

The builder writes no key of build-agent or of the toolchain bases its
builds stand on, so a walk moving one would hold its tier for ever.
Until R4g they are build-agent's own, as the builder's module is; the
bases are read from the toolchains, not copied.
This commit is contained in:
2026-10-22 21:06:33 +02:00
parent 93fc2f48a1
commit 9713ceb84d
3 changed files with 81 additions and 5 deletions
+18
View File
@@ -234,6 +234,24 @@ func spoken() string {
}
// Languages is every language the mesh can build, for anything that wants to say so.
// AgentModule is build-agent's own module: the machine's builder, whose image is built from another repository's context.
const AgentModule = "build-agent"
// Bases are the modules whose artifacts provide the toolchains' compilers (Toolchain.Base), each once, sorted: images
// build-agent's builds stand on.
func Bases() []string {
seen := map[string]bool{}
var out []string
for _, t := range toolchains {
if t.Base != "" && !seen[t.Base] {
seen[t.Base] = true
out = append(out, t.Base)
}
}
sort.Strings(out)
return out
}
func Languages() []string {
names := make([]string, 0, len(toolchains))
for _, t := range toolchains {