Add YAML anchor/alias expansion.

This commit is contained in:
monopole
2021-08-10 14:18:26 -07:00
parent 6c4e8019f8
commit 360585dfaf
6 changed files with 207 additions and 9 deletions

View File

@@ -607,6 +607,16 @@ func (m *resWrangler) ToRNodeSlice() []*kyaml.RNode {
return result
}
// DeAnchor implements ResMap.
func (m *resWrangler) DeAnchor() (err error) {
for i := range m.rList {
if err = m.rList[i].DeAnchor(); err != nil {
return err
}
}
return nil
}
// ApplySmPatch applies the patch, and errors on Id collisions.
func (m *resWrangler) ApplySmPatch(
selectedSet *resource.IdSet, patch *resource.Resource) error {