generated from mathias/template-go-web
feat(atlas): hybrid substrate — live specs for cluster nodes, authored rest
MergeSubstrate overlays live node specs onto the authored machine list by name: cluster nodes (koala) get fresh live specs, non-cluster machines (iguana/flamingo/ piguard) stay authored, new live nodes are appended. Test-first. Restores the full homelab machine list while keeping cluster nodes truthful. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -38,7 +38,7 @@ func NewHandler() http.Handler {
|
||||
return
|
||||
}
|
||||
if live := liveSubstrate(); len(live) > 0 {
|
||||
a.Substrate = live
|
||||
a.Substrate = atlas.MergeSubstrate(a.Substrate, live)
|
||||
}
|
||||
w.Header().Set("Content-Type", "application/json; charset=utf-8")
|
||||
_ = json.NewEncoder(w).Encode(a)
|
||||
|
||||
Reference in New Issue
Block a user