-
Notifications
You must be signed in to change notification settings - Fork 208
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
Add Secret resource into Helm chart to allow passing sensitive values to config via environment variables #1502
base: main
Are you sure you want to change the base?
Conversation
… via environment variables
* add secret template * align logic with upstream PR: grafana/alloy#1502
ping @grafana/grafana-agent-maintainers for a review. No input for doc in the PR in it's current state. |
@petewall pinging you on this PR because it's about the helm chart |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Personally, I don't know if I see the value for this, since this chart already has a envFrom
, which lets you already do this:
envFrom:
- secretRef:
name: mySecret
The only difference is that this chart would create a secret for you, which, I guess is helpful. It feels like this chart doing too much, IMO.
PR Description
This PR introduces a new Secret resources into the Helm chart which is used to store sensitive values as environment variables and populate them into the Alloy container to be read within the Alloy config using the
env
directive.This allow for sensitive values to be stored in a Secret rather than in the ConfigMap or the Pod definition.
Notes to the Reviewer
I did my best to add some meaningful examples on how those secret values are defined and used from the config, but I am open to suggestions.
I would also appreciate some guidance on how to update the Helm chart tests.
PR Checklist