Add optional annotations to secrets #1599
Open
+18
−0
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description: Add optional annotations to be passed for secrets.
My team uses a mutating webhook to inject secrets on create. We utilize annotations as part of this webhook which this chart does not currently support.
Testing: This is an optional value, and tested that no examples show any changes when rendering. I also tested rendering with the below test value file to verify my changes show up correctly. I did not think this change warranted a new example to be created.
Documentation: Updated values schema.
Note:
I went with an if conditional in the templates because I saw it was done this way in the serviceAccount.yaml file:
https://github.com/signalfx/splunk-otel-collector-chart/blob/main/helm-charts/splunk-otel-collector/templates/serviceAccount.yaml#L20-L23
Afterwards I noticed that the service.yaml uses with instead:
https://github.com/signalfx/splunk-otel-collector-chart/blob/main/helm-charts/splunk-otel-collector/templates/service.yaml#L17-L20
I don't know if there is a preference but I can change if requested.