I think I had the same question around YAML anchors/references a couple of years ago and in 0.12 at least I believe they were intentionally not supported.
That being said we are using them in a Kubernetes deploy action in order to not duplicate all the Ingress http routing rules a bunch of times. I believe that works because they are passed straight onto the K8s cluster without much interpretation by Garden.
I second the config templates suggestion above though.
01/23/2024, 4:05 AM
the workaround is probably to define a secret/configmap resource with garden using patchresources to insert the runtime values, then refer to that secret/configmap in the deployment manifest to avoid having multiple duplicate patchresources blocks