Skip to content
This repository has been archived by the owner on Nov 1, 2022. It is now read-only.

be able to pass args to helm on upgrades #1621

Closed
davidkarlsen opened this issue Dec 28, 2018 · 6 comments
Closed

be able to pass args to helm on upgrades #1621

davidkarlsen opened this issue Dec 28, 2018 · 6 comments
Labels

Comments

@davidkarlsen
Copy link
Contributor

It would be useful to be able to pass arguments to helm on upgrades (via the helm operator).
Specifically I am looking for --reset-values.
The reason for this is that I sometimes install initially with some overriding values, but later on want to use the chart-defaults. This is not possible as it is now - if you ever installed with some specific values initially, you cannot fallback to the defaults by removing the overriding values in the values: section of the HelmRelease anymore.

@stefanprodan
Copy link
Member

The Helm Operator is using the helm go client not the CLI, so passing args is not possible. The reset-values option could be part of the CRD something like:

apiVersion: flux.weave.works/v1beta1
kind: HelmRelease
metadata:
  name: redis
spec:
  releaseName: redis
  timeout: 600
  resetValues: true
  chart:
    repository: https://kubernetes-charts.storage.googleapis.com/
    name: redis
    version: 5.1.3
  valueFileSecrets:
    - name: redis-auth
  values:
    usePassword: true

@squaremo
Copy link
Member

@davidkarlsen This makes sense -- it's a "release the chart with exactly these values" mode. On that basis, I would expect you'd want it to reset every time it runs upgrade?

@davidkarlsen
Copy link
Contributor Author

davidkarlsen commented Dec 31, 2018

I would expect the same result as helm upgrade --install --reset-values - f values.yaml

That way the chart version plus the current config in git is the result. Regardless of any history

@squaremo
Copy link
Member

That way the chart version plus the current config in git is the result. Regardless of any history

Got it 👍 Then yep I think a field in the HelmRelease is a good way to expose this option.

@stefanprodan
Copy link
Member

I’v implemented this in the reset-values branch https://github.com/weaveworks/flux/tree/reset-values

I’ll make a PR next year :)

@c4m4
Copy link

c4m4 commented Apr 2, 2020

Using resetValues: false on an existing helm release doesn't works, I've already opened an issue fluxcd/helm-operator#352

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

4 participants