Say what a container's host entries now are #60

Merged
jschoubben merged 1 commits from feat/148-names-are-resolved-not-copied into main 2026-09-30 12:38:15 +00:00
+9 -7
View File
@@ -1501,13 +1501,15 @@ func containerSpecReading(r *declaration.Container, declares, reads map[string]s
for _, a := range r.Args { for _, a := range r.Args {
b.WriteString("arg " + a + "\n") b.WriteString("arg " + a + "\n")
} }
// **The mesh's names are part of what a container is** (novox/hq 04-ISSUES/135). A container // **A container's declared names are part of what it is** (novox/hq 04-ISSUES/135). What is
// resolves every other machine and every public name through the entries the mesh gives it at // here is what the module declared for itself and nothing else: the mesh's own names are no
// creation, and nothing re-reads them afterwards — so a container left alone when the roster // longer written into a container (ADR 0148) — they were once, every container got the whole
// moved is one that cannot reach anything by name, for ever, while every check reports it // roster at creation and nothing re-read it, so one left alone when the roster moved could not
// running. That is exactly what happened when this mesh's overlay range changed: one container // reach anything by name for as long as it ran while every check reported it running; and once
// whose image and files never changed kept an address five days out of date and restarted // the roster was in this digest so that could be caught, one name moving anywhere replaced
// 2286 times against a database it could no longer find. // every container in the mesh (04-ISSUES/151). A container resolves a mesh name through the
// machine's resolver at the moment it asks. What a module declares does not move when the
// roster does, so hashing it costs nothing and catches a manifest that changed.
// //
// Sorted, so the digest does not move for a reordering nobody made. // Sorted, so the digest does not move for a reordering nobody made.
hosts := append([]string(nil), r.Hosts...) hosts := append([]string(nil), r.Hosts...)