ory / k8s

Kubernetes Helm Charts for the ORY ecosystem.
https://k8s.ory.sh/helm
Apache License 2.0
336 stars 259 forks source link

fix: use the correct values naming within hydra-maester for consistency #484

Closed adamstrawson closed 2 years ago

adamstrawson commented 2 years ago

The use of annotation within hydra-maester is inconsistent with the other Ory Helm Charts, as well as it's own documentation.

The hydra-maester documentation specified deployment.annotations already, and the other charts use the same format.

BREAKING CHANGES: This patch changes the behavior of configuration item `annotation`. To keep the existing
behavior please do `deployment.annotation`.

Checklist

Demonsthere commented 2 years ago

Hi there! You are correct, the values is not consistent with the rest of the ory ecosystem :/ However your method introduces a breaking change, instead I would suggest the usage of ternary operator:

{{- $annotations := ternary .Values.deployment.annotations .Values.deployment.annotation (not (empty .Values.deployment.annotations )) -}}

this format would support both and not be a breaking change :) Please add in your PR an empty object as the default value for annotations, and some test annotations to the test overrides in the hack folder :)