You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We just introduced the yaml-update step, which is a great improvement over helm-update-image. Now we should add an equivalent json-update step to deal with json files.
Motivation
This would enable users who use other config management tools like .jsonnet or grafana tanka. Somone using jsonnet could patch an image tag to a .json. Technically they could even patch a .jsonnet file, as long as that file was pure json and did not use any jsonnet syntax.
Suggested Implementation
Step syntax can follow the same syntax as yaml-update but understand how to manipulate a JSON file.
As a future improvement, we could consider leaving room for different patching types (JSON Patch, JSON Merge Patch), but I would not consider this required for MVP. Also, I do not think we should support strategic merge patch, which is a can of worms I would not want to go down.
The text was updated successfully, but these errors were encountered:
Adding a note here that, as we discussed offline, I think it's important to preserve formatting and field order. (We took great care to do so with YAML.) If we don't it creates noise in the diffs.
Proposed Feature
We just introduced the
yaml-update
step, which is a great improvement overhelm-update-image
. Now we should add an equivalentjson-update
step to deal withjson
files.Motivation
This would enable users who use other config management tools like .jsonnet or grafana tanka. Somone using jsonnet could patch an image tag to a
.json
. Technically they could even patch a.jsonnet
file, as long as that file was pure json and did not use any jsonnet syntax.Suggested Implementation
Step syntax can follow the same syntax as
yaml-update
but understand how to manipulate a JSON file.As a future improvement, we could consider leaving room for different patching types (JSON Patch, JSON Merge Patch), but I would not consider this required for MVP. Also, I do not think we should support strategic merge patch, which is a can of worms I would not want to go down.
The text was updated successfully, but these errors were encountered: