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

Support fetching secrets from Vault #988

Open
mhutter opened this issue Jun 25, 2021 · 2 comments
Open

Support fetching secrets from Vault #988

mhutter opened this issue Jun 25, 2021 · 2 comments
Assignees
Labels

Comments

@mhutter
Copy link

mhutter commented Jun 25, 2021

Some tools like ArgoCD allow you to pull some secret values from vault by setting values in manifests to something like '?{vaultkv:path/to/vault/key}'. Those references are replaced by the actual value from vault before applying the manifest to the cluster.

However, since the chart renders all secrets as base64-encoded, ArgoCD cannot detect & replace those values.

Possible fixes

  1. Don't base64-encoded secret values and use stringData instead of data
  2. Allow using existing secrets so the secrets can be provided by other means. This is a common pattern in other charts, see https://github.com/minio/charts/blob/a5c84bcbad884728bff5c9c23541f936d57a13b3/minio/values.yaml#L76-L91 for an example

If this is something you want to support I could send you a PR for option 1

@ninjadq ninjadq self-assigned this Jul 8, 2021
@ninjadq
Copy link
Member

ninjadq commented Jul 8, 2021

Hi, what secret value you wanna replace? We also provides secret config in values.yaml. are those config met your use case?

@mhutter
Copy link
Author

mhutter commented Jul 8, 2021

We want to set fields like the default admin password, HTTP secrets and similar.

In our pipeline we use helm template to render out all manifests, and then use ArgoCD to apply the manifests.
ArgoCD supports fetching the actual VALUE for a secret only when it is applied to the Kubernetes API.

In order to do that, ArgoCD must be able to identify values which reference a Vault entry before applying the manifest to the cluster. And this only works when Secret values are provided as stringData as opposed to data (since the data entries are base64-encoded and ArgoCD cannot determine whether this holds a Vault reference or binary data).

@zyyw zyyw added kind/requirement backlog help wanted Extra attention is needed labels Jan 13, 2022
@zyyw zyyw assigned zyyw and unassigned ninjadq Jan 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants