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

Support helm chart placeholder repositories #4681

Closed
rarkins opened this issue Oct 17, 2019 · 5 comments · Fixed by #4844
Closed

Support helm chart placeholder repositories #4681

rarkins opened this issue Oct 17, 2019 · 5 comments · Fixed by #4844
Labels
help wanted Help is needed or welcomed on this issue manager:helm Helm package manager type:feature Feature (new functionality)

Comments

@rarkins
Copy link
Collaborator

rarkins commented Oct 17, 2019

What would you like Renovate to be able to do?

Support placeholders like this:

dependencies:
  - name: generic-service
    version: 5.0.2
    repository: '@axoom-github'
    alias: app

Also support alias:axoom-github too as allowed in helm/helm#2174

Describe the solution you'd like

It seems we need to check other yaml files within the repo for placeholder values. Is the location deterministic?

Describe alternatives you've considered

Currently we just skip placeholders, so they're not updated.

Additional context

Example source: https://github.com/AXOOM/Templates.WebService/blob/b7fca8e6a8aa94283a4aa4a1a98c92d77d6d4f55/content/helmfile.yaml#L6-L8

@rarkins rarkins added type:feature Feature (new functionality) help wanted Help is needed or welcomed on this issue needs-requirements manager:helm Helm package manager labels Oct 17, 2019
@rarkins
Copy link
Collaborator Author

rarkins commented Oct 17, 2019

@bastianeicher @gordonbondon @srueg @BugRoger appreciate your inputs here if you have any

@gordonbondon
Copy link

gordonbondon commented Oct 17, 2019

This is repo alias(helm/helm#2174) and it works when helm repo was added locally with helm repo add <name> <url>. It supports two formats @<name> and alias:<name>.

Tools like helmfile in your example provide options to do this helm repo add automatically before applying, but there are a lot of tools like this (like helmsman), and they have different formats for this, so I'm not sure it makes sense to try to support them all.

You can get a list of name-url pairs after they were added by doing helm repo list or checking ~/.helm/repository/repositories.yaml

@rarkins
Copy link
Collaborator Author

rarkins commented Oct 17, 2019

Ideally we want to do this without shelling out to third party binaries. Being able to scan/parse in a browser or pass unit tests without installing a dozen binaries is important to the project.

In the AXOOM example the placeholder definition is in helmfile.yaml while the requirements are in charts/requirements.yaml. Is it safe to always look into "../requirements.yaml" for the "repositories" array, or could they be defined elsewhere in a repository?

@bastianeicher
Copy link
Contributor

bastianeicher commented Oct 18, 2019

Hi @rarkins,

first of all, thanks for taking a look at our GitHub projects. :)

In Helm, in order for a repository to be usable it must always be registered first with helm repo add aliasname https://someurl. Afterwards it can be referenced either in a requirements.yaml either as @aliasname or https://someurl.

Even when you don't intend to use the alias name, you still need to perform the helm repo add call. So since I'm already setting an alias, I usually decide to use it in the requirements.yaml rather than repeating the URL.

This works well enough if there's a helmfile.yaml in the same repository which automatically takes care of calling helm repo add, but there really is no well established standard for where such a file might be in a repository (if it is in the same repo as the chart at all).

How about adding a new config option to renovate.json that allows a user to specify Helm repo aliases?

Regards
Bastian

@renovate-release
Copy link
Collaborator

🎉 This issue has been resolved in version 19.69.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 16, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
help wanted Help is needed or welcomed on this issue manager:helm Helm package manager type:feature Feature (new functionality)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants