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

Extension points for custom labels and annotations in each resource #115

Open
jaolwi opened this issue Mar 25, 2024 · 0 comments
Open

Extension points for custom labels and annotations in each resource #115

jaolwi opened this issue Mar 25, 2024 · 0 comments

Comments

@jaolwi
Copy link

jaolwi commented Mar 25, 2024

To make the chart as customizable as possible for users, it would be good to create entrypoints in all resources for labels and annotations. Annotations and labels are often used by clusters to implement network rules or to inject sidecars.

Possible solution:

There are examples in the postgresql charts from Bitnami.
The best way to implement this is probably to use the "with" statement.

#values.yaml
web:
 extraLabels: {}
 extraAnnotations: {}

#web-deploy.yaml
labels:
  {{- with .Values.web.extraLabels }}
    {{- toYaml . | nindent 8 }}
  {{- end }}
annotations:
  {{- with .Values.web.extraAnnotations }}
    {{- toYaml . | nindent 8 }}
  {{- end }}
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

1 participant