controller v0.269.0: whole restore from the second drive; crash loops stopped; exact image digests; steps judged by their own .felhom.yml (decisions 26-28, R-661 R-666 R-667 R-668 R-664 R-665 R-662, 09 6.4 part 6)
gates / gates (push) Successful in 27s

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0159rPz1ZhFKsS53msqPYxtS
This commit is contained in:
2026-09-24 12:18:39 +02:00
parent 7c3b3a9694
commit 3c6b49b31c
141 changed files with 3401 additions and 237 deletions
+8 -5
View File
@@ -328,12 +328,12 @@ func (m *Manager) CatalogTemplatePath(appName, filename string) string {
// the syncer has already copied the catalog verbatim into its stack dir, so `pull` + `up -d` do
// today's job with no help from here.
func (m *Manager) advancePinToCatalog(name, stackDir string) error {
return m.advancePinTo(name, stackDir, m.CatalogTemplatePath(name, "docker-compose.yml"))
return m.advancePinTo(name, stackDir, m.CatalogTemplatePath(name, "docker-compose.yml"), m.CatalogTemplatePath(name, ".felhom.yml"))
}
// advancePinTo is advancePinToCatalog with the definition named: the catalog's current compose file,
// or — on a ladder (v0.268.0, `09` §3 decision 14) — one step's own definition from `steps/`.
func (m *Manager) advancePinTo(name, stackDir, src string) error {
func (m *Manager) advancePinTo(name, stackDir, src, metaSrc string) error {
cfg := LoadAppConfig(stackDir)
if cfg == nil || len(cfg.PinnedImages) == 0 {
return nil // unpinned — today's behaviour, unchanged
@@ -346,6 +346,8 @@ func (m *Manager) advancePinTo(name, stackDir, src string) error {
return fmt.Errorf("cannot read the catalog's current definition for %s (%s): %w", name, src, err)
}
// v0.269.0 (`09` §6.4 part 6): run EXACTLY the tested images — the ladder entry's digests for these refs.
data = RenderWithLadderDigests(filepath.Dir(m.CatalogTemplatePath(name, "docker-compose.yml")), data)
live := ComposePathIn(stackDir)
if err := StoreAppliedDefinition(stackDir, data); err != nil {
return fmt.Errorf("storing the new applied definition for %s: %w", name, err)
@@ -365,8 +367,9 @@ func (m *Manager) advancePinTo(name, stackDir, src string) error {
}
m.mu.Unlock()
// v0.263.2: the new version's own .felhom.yml becomes the pinned version's record.
m.storeAppliedMetaFrom(name, stackDir, m.CatalogTemplatePath(name, ".felhom.yml"))
m.logger.Printf("[INFO] [stacks] update %s: pin advanced to the catalog's current definition (%s)", name, summarisePin(pin))
// v0.263.2: the new version's own .felhom.yml becomes the pinned version's record — the STEP's own
// when the ladder carries one (R-664, v0.269.0).
m.storeAppliedMetaFrom(name, stackDir, metaSrc)
m.logger.Printf("[INFO] [stacks] update %s: pin advanced to %s (%s)", name, src, summarisePin(pin))
return nil
}