Make the apiVersion
and kind
fields mandatory in Kustomization/Component v1
#5140
Labels
kind/feature
Categorizes issue or PR as related to a new feature.
priority/important-longterm
Important over the long term, but may not be staffed and/or may need multiple releases to complete.
triage/accepted
Indicates an issue or PR is ready to be actively worked on.
Projects
Eschewed features
What would you like to have added?
We add the warning message when the
apiVersion
orkind
fields are omitted.Why is this needed?
Today,
kustomize
accept to omit theapiVersion
andkind
fields.This syntax is easy to start for new users, but it isn't very clear and maybe break the user config when we have a few
apiVersion
versions (Ex. when we addv1
forapiVersion
).So, Could we consider deprecating this syntax that omits the
apiVersion
andkind
fields?I think we can start by showing the warning message and adding the auto-fix function. And we can make more consideration to whether remove or not.
Can you accomplish the motivating task without this feature, and if so, how?
Probably, we can decide to use current values (Ex.
apiVersion: kustomize.config.k8s.io/v1beta1
) when that fields omitted.These values were hardcoded on codes and we can announce for we require set these values when you need to use
v1
and new functions.But I think we need to add the warning message because we must remove the old apiVersion in the future.
What other solutions have you considered?
Probably, we have enough to add the warning message only.
But if we don't deprecate that, maybe user got to break their config when updating
kustomize
.Anything else we should know?
No response
Feature ownership
The text was updated successfully, but these errors were encountered: