qbec icon indicating copy to clipboard operation
qbec copied to clipboard

why does expandHelmTemplate deprecated

Open vm86 opened this issue 3 years ago • 4 comments

Hi! I found deprecated warning in docs. https://github.com/splunk/qbec/blame/main/site/content/reference/jsonnet-native-funcs.md#L10

The commit was created about two years ago.

Why was this function stayed deprecated? It is very convenient to use. I suggest to delete this deprecated warning and continue to support this function.

vm86 avatar Oct 08 '22 09:10 vm86

As additional point: if ever #265 helm datasource will be implemented, datasources exists only for qbec, not for jsonnet-qbec. So some of the functionality of the jsonnet-qbec will be lost.

Andor avatar Dec 29 '22 10:12 Andor

the only problem is one of maintaining this function that was written for helm2 and make sure it still works for helm3. I'm ok leaving it in if that is what people want.

gotwarlost avatar Jan 03 '23 16:01 gotwarlost

function that was written for helm2 and make sure it still works for helm3

We tested it with helm3 and it just works. Documentation need to be updated tho because some options (name) from helm2 doesn't exists for helm3.

Also, could you please take a look at Tanka's implementation of helm integration, maybe you will find it a bit more handy: https://tanka.dev/helm and https://github.com/grafana/jsonnet-libs/blob/master/tanka-util/helm.libsonnet

Andor avatar Jan 03 '23 19:01 Andor

So, for example, this code just works:

local argocd = std.native('expandHelmTemplate') (
  'https://github.com/argoproj/argo-helm/releases/download/argo-cd-5.51.4/argo-cd-5.51.4.tgz',
  params.values,
  {
    namespace: params.namespace,
    nameTemplate: 'argocd',
    thisFile: std.thisFile,  // important
  },
);

Andor avatar Nov 27 '23 15:11 Andor