Document how to add Helm Charts to the GitLab Container Registry
Release notes
Helm 3 supports OCI for package distribution. Chart packages are able to be stored and shared across OCI-based registries. This means you can easily publish Helm charts to your GitLab Container Registry. In fact, this functionality has been working for some time but we have not yet documented it.
This issue adds documentation for how you can use the Helm client to login, publish, view, and install Helm charts stored in the Container Registry. One issue is that you can't yet distinguish between helm charts and images in the user interface, but we hope to address that in early 2021.
Problem to solve
GitLab does not currently have documentation on how to publish Helm charts to the Container Registry. It's documented by Helm here but we should have GitLab specific documentation.
Proposal
Add a topic to the Container Registry documentation that describes how to login, publish, view and install Helm charts to the registry.
Example .gitlab-ci.yml
image:
name: "dtzar/helm-kubectl:3.0.1"
entrypoint: ["/bin/sh","-c"]
stages:
- build
build_chart:
stage: build
variables:
IMAGE: $CI_REGISTRY_IMAGE/$CI_COMMIT_REF_SLUG:1.1.0
script:
- export HELM_EXPERIMENTAL_OCI=1
- helm chart save . $IMAGE
- helm registry login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" $CI_REGISTRY
- helm chart push $IMAGE