Skip to content
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

Invalid manifest creation due to lack of guards around labels #918

Open
nabadger opened this issue Aug 2, 2024 · 1 comment
Open

Invalid manifest creation due to lack of guards around labels #918

nabadger opened this issue Aug 2, 2024 · 1 comment

Comments

@nabadger
Copy link

nabadger commented Aug 2, 2024

Describe the bug
Using default values the helm template generates invalid manifests.

To Reproduce

helm template myapp . 

You will end up with something like:

apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
  name: myapp-operator-manager-role
  labels:
  namespace: default
...

This happens on multiple resources.

I think the bulk of the issues come from the operator, for example: https://github.com/kubeshop/helm-charts/blob/main/charts/testkube-operator/templates/rolebinding.yaml#L8

It's also not clear where globalLabels comes from (not sure it's specified as an option in values.yaml)

Expected behavior
If there are no label values defined the labels field should not be present.

Version / Cluster

  • Which testkube version? Chart version 2.0.17
@vsukhin
Copy link
Contributor

vsukhin commented Aug 2, 2024

thank you @nabadger I will ask our devops engineers @ypoplavs @dejanzele to check it out

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants