-
Notifications
You must be signed in to change notification settings - Fork 2.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Labels support for Transformer Configurations #5527
Comments
/assign @stormqueen1990 |
Highly interested as well! |
Hello there, @ciaccotaco! 👋 The The configuration I tested looks similar to the following: labels:
- includeSelectors: false # or true
includeTemplates: true # or false
pairs:
app: myapp
contact: username
department: kustomize
environment: dv
fields:
- path: spec/podTemplate/metadata/labels
create: true
kind: FlinkDeployment
- path: spec/jobManager/podTemplate/metadata/labels
create: true
kind: FlinkDeployment
- path: spec/taskManager/podTemplate/metadata/labels
create: true
kind: FlinkDeployment
resources:
- resources/flinkdeployment.yaml Note the absence of the |
/kind support |
/remove-kind feature |
Hi @stormqueen1990 👋 I tested your suggestion and it indeed works - I guess I should have rtfm! Our GitOps pipeline uses a common set of configs that are referenced when applications are promoted between environments. Having transformer configuration support for While a desirable feature, I understand if it is something that cannot be implemented. We can certainly make things work using Thanks! Edit: It currently is not in the manual. Thank you for creating an issue to add it. |
Nice to know this addresses your use case! I added a note to record this feedback in #5436 (comment), as the deprecation of I will be closing this issue but feel free to reopen if needed! /close |
@stormqueen1990: Closing this issue. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Eschewed features
What would you like to have added?
Currently (as of kustomize 5.3.0), there is no
labels
support for Transformer Configurations. It would be beneficial to add support forlabels
, ascommonLabels
is deprecated.Why is this needed?
This is needed because
commonLabels
is deprecatedlabels
in the base kustomizationl.yaml file only works with acommonLabels
transformer configuration whenincludeSelectors: true
is configured. If the granularity for not including selectors (or templates) is needed, then there is no support for alabels
transform configuration.Can you accomplish the motivating task without this feature, and if so, how?
There is no way to use custom transformer configurations with
labels
and a combination ofincludeSelectors: false
).What other solutions have you considered?
The only option is to continue using the
commonLabels
transformer config andlabels
withincludeSelectors: true
Anything else we should know?
Example
An example of what the end user would configure is the following:
YAMLs
File Structure
Base Kustomization
Transformer Configuration
Resource
Output
Feature ownership
The text was updated successfully, but these errors were encountered: