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

Add support for Helm charts from OCI registries #834

Merged
merged 2 commits into from
Mar 25, 2022

Conversation

graillus
Copy link
Contributor

Since version 3.8.0 Helm supports OCI registries for chart storage https://helm.sh/docs/topics/registries, but the helm pull command used to fetch a chart from an OCI registry slightly changes, the --repo flag have to be omitted because it only works with http(s) chart repositories. Helm expects the fully-qualified URL to the chart instead as argument.

Proposed Changes

This PR adds support for Helm chart dependencies from OCI registries by removing the --repo flag passed to the helm command when the oci:// prefix is detected in the source property, and pass it as argument instead.

For instance, this configuration:

  kapitan:
    dependencies:
    - type: helm
      output_path: charts/example
      source: oci://europe-west1-docker.pkg.dev/my-project/helm-charts/example
      version: 1.2.3
      chart_name: example

will generate the following Helm command:

helm pull --destination charts/example --untar --version 1.2.3 oci://europe-west1-docker.pkg.dev/my-project/helm-charts/example

@ademariag
Copy link
Contributor

Sweet @graillus ! Thank you, we'll review it!

If you haven't already, join our #kapitan channel on https://kubernetes.slack.com

@graillus graillus force-pushed the feat/support-helm-oci-registries branch from bf5a644 to e4c0640 Compare March 24, 2022 09:28
@ramaro
Copy link
Member

ramaro commented Mar 25, 2022

Thanks @graillus! LGTM :D

@ramaro ramaro merged commit 85fe799 into kapicorp:master Mar 25, 2022
@graillus graillus deleted the feat/support-helm-oci-registries branch March 25, 2022 17:48
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

Successfully merging this pull request may close these issues.

None yet

4 participants