mirror of
https://github.com/kubernetes-sigs/kustomize.git
synced 2026-06-29 17:41:13 +00:00
Manage name changes (prefix/suffix) via YAML annotations rather than via in-memory-only fields.
This commit is contained in:
@@ -108,6 +108,7 @@ func (p *plugin) transformJson6902(m resmap.ResMap, patch jsonpatch.Patch) error
|
||||
return err
|
||||
}
|
||||
for _, res := range resources {
|
||||
res.SetOriginalName(res.GetName(), false)
|
||||
err = res.ApplyFilter(patchjson6902.Filter{
|
||||
Patch: p.Patch,
|
||||
})
|
||||
|
||||
@@ -306,7 +306,7 @@ path: patch.yaml
|
||||
target:
|
||||
name: myDeploy
|
||||
`, someDeploymentResources)
|
||||
th.AssertActualEqualsExpected(rm, `
|
||||
th.AssertActualEqualsExpectedNoIdAnnotations(rm, `
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
|
||||
Reference in New Issue
Block a user