https://pulumi.com logo
#kubernetes
Title
# kubernetes
g

glamorous-teacher-20849

01/11/2024, 2:10 AM
Having great difficulties installing the grafana loki helm chart. Pulumi insists it doesn't exist..
Copy code
error: kubernetes:<http://helm.sh/v3:Release|helm.sh/v3:Release> resource 'loki': property chart value {grafana/loki} has a problem: chart "grafana/loki" version "5.41.5" not found in <https://grafana.github.io/helm-charts> repository; check the chart name and repository configuration.
But it does...
grafana/loki                    5.41.5          2.9.3
Copy code
var loki = new Release("loki", new ReleaseArgs()
        {
            Name = "loki",
            Namespace = lokiNs.Metadata.Apply(x=>x.Name),
            Chart = "grafana/loki",
            Version = "5.41.5",
            RepositoryOpts = new RepositoryOptsArgs
            {
                Repo = "<https://grafana.github.io/helm-charts>"
            },
            Values = lokiValues
        }, new CustomResourceOptions()
        {
            Provider = k8sProvider
        });
Any ideas?
c

cuddly-computer-18851

01/11/2024, 2:16 AM
what about
5.41.4
?
g

glamorous-teacher-20849

01/11/2024, 2:17 AM
I got it working. For some reason I usually get things working moments after publicly asking for help. I had to drop "grafana/" from the chart name. It doesn't make any sense to me as its listed as "grafana/loki"
c

cuddly-computer-18851

01/11/2024, 2:18 AM
I'm about to try to install the grafana-agent operator chart so hopefully this helps me 😆
g

glamorous-teacher-20849

01/11/2024, 2:21 AM
potentially hours saved 🙂
d

dry-keyboard-94795

01/11/2024, 2:29 AM
When using the helm cli, you're specifying both the repo name and the Chart name.
helm repo add grafana <https://grafana.github.io/helm-charts|https://grafana.github.io/helm-charts>
adds the repo named 'grafana', which has a chart named 'loki' in it. In pulumi, you specific the repo explicitly, so forgo the repo name
g

glamorous-teacher-20849

01/11/2024, 4:36 AM
This chart is pain. Refuses to let me set the affinity of anything other than "backend"
backend.affinity
. write.affinity 💥 read.affinity 💥 gateway.affinity 💥
Copy code
error: template: loki/templates/gateway/deployment-gateway.yaml:104:16: executing "loki/templates/gateway/deployment-gateway.yaml" at <.>: wrong type for value; expected string; got map[string]interface {}
Docs say
Affinity for gateway pods. Passed through tpl and, thus, to be configured as string
... sounds it wants yaml as a string?!