Skip to content

Different behavior between helm from brew and helm from the get.helm.sh #13174

Closed
Homebrew/homebrew-core
#177094

Description

@davinkevin

I have a strange behavior when I use helm template, and this is different based on the helm distribution I use (from brew or from get.helm.sh).

The evaluation of .Capabilities.KubeVersion.Version is different based on the helm distribution I use.

With the simplest chart possible:

apiVersion: v1
kind: ServiceAccount
metadata:
  name: foo
  annotations:
    version: {{ .Capabilities.KubeVersion.Version }}

If I render this with helm from get.helm.sh, I have:

$ ./.bin/helm template foo
---
# Source: foo/templates/serviceaccount.yaml
apiVersion: v1
kind: ServiceAccount
metadata:
  name: foo
  annotations:
    version: v1.30.0

If I do this with the version installed with brew:

$ /opt/homebrew/Cellar/helm/3.15.3/bin/helm template foo
---
# Source: foo/templates/serviceaccount.yaml
apiVersion: v1
kind: ServiceAccount
metadata:
  name: foo
  annotations:
    version: v1.20.0

You can see the version is 1.20.0 for the brew distribution and 1.30.0 for helm standard.

You can find a project with reproducers and Taskfile to run commands

Output of helm version:

The one from brew:

version.BuildInfo{Version:"v3.15.3", GitCommit:"Homebrew", GitTreeState:"clean", GoVersion:"go1.22.5"}

The one from get.helm.sh:

version.BuildInfo{Version:"v3.15.3", GitCommit:"3bb50bbbdd9c946ba9989fbe4fb4104766302a64", GitTreeState:"clean", GoVersion:"go1.22.5"}

I expect the value to be the same, and eventually for me the 1.30 which is the highest value.

Output of kubectl version: N/A, I'm not connected to a cluster and use only helm template.

Cloud Provider/Platform (AKS, GKE, Minikube etc.): None

Activity

  1. chenrui333 commented on Jul 12, 2024

    @chenrui333
    Contributor

    should be fixed with Homebrew/homebrew-core#177094

  2. gjenkins8 commented on Jul 26, 2024

    @gjenkins8
    Member

    Thanks @chenrui333 !

  3. gjenkins8 commented on Jul 26, 2024

    @gjenkins8
    Member

    @davinkevin -- the reason is that the hoomebrew build was not passing the same ldflags as the "native" build for get.helm.sh

  4. davinkevin commented on Jul 30, 2024

    @davinkevin
    Author

    Yep, I checked the PR 😉 . And I think I have the new version now.

    image
  5. github-actions commented on Aug 21, 2025

    @github-actions

    This issue has been marked as stale because it has been open for 90 days with no activity. This thread will be automatically closed in 30 days if no further activity occurs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions