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

Cannot push helm chart with same version but different metadata #68

Open
guenaelthiriet opened this issue Dec 3, 2018 · 1 comment
Open

Comments

@guenaelthiriet
Copy link

guenaelthiriet commented Dec 3, 2018

Hi,

We use the following version scheme for our charts "1.0.0+24.abc" : 1.0.0 is the version and the rest is build metadata (# of commits since last tag, and git commit abbrev)
The helm docs says it is supported: https://docs.helm.sh/developing_charts/#charts-and-versioning

The first time a chart with version 1.0.0+24.abc is pushed it works fine.
If we make changes in our code and create a new chart with version 1.0.0+25.def is generated.
When trying to push that chart, it gets rejected, saying the version already exists:

The chart already exists in the repository and cannot be overwritten without an explicit intent. If you want to replace existing chart, use --force flag:

    helm s3 push --force server-0.0.1+128.62d899d.tgz charts

Error: plugin "s3" exited with error

After some digging, the problem seems to be related to the way caches are built in the plugin. They rely on major, minor, patch only. In my case the cache would already contain a 1.0.0 entry so it would refuse to push a new 1.0.0 version.

Would it be wrong to use the full version, including the metadata?

Thanks,
Guenael

@steven-sheehy
Copy link

Helm uses semantic versioning and the version you supplied does not follow semantic versioning rules. The library that is parsing your version cannot understand they are two different versions because of this.I don't think there's any issue with the helm s3 plugin. You have two choices:

  1. Use the --force and push it anyway
  2. Use a version like 1.0.0-128.abc to indicate pre-release versions. e.g. switch + with -

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

No branches or pull requests

2 participants