Environment setup

To set up for charts development, command line tools and a Kubernetes cluster are required.

Required developer tools

The minimum tools required for charts development are documented on the Required tools page.

You should use asdf to install these tools. This allows us to easily switch between versions, Helm 3.4 and 3.5 for example.

We provide a .tool-versions file that specifies these tools with their recommended versions. To install or update them:

  1. Clone the charts repository and change directory:

    git clone https://gitlab.com/gitlab-org/charts/gitlab.git charts-gitlab
    cd charts-gitlab/
    
  2. Add each plugin repository. This only has to be done once:

    asdf plugin add minikube
    asdf plugin add kubectl
    asdf plugin add helm
    asdf plugin add stern
    asdf plugin add vale
    
  3. Install or update the tools:

    asdf install
    

Additional developer tools

Developers working on charts also often use the following tools:

Tool nameBenefitsExample use caseLink(s)
asdfEasily switch between versions of your favorite runtimes and CLI tools.Switching between Helm 3.4 and Helm 3.5 binaries.GitHub
kubectx & kubens Manage and switch between Kubernetes contexts and namespaces.Setting default namespace per selected cluster context.GitHub
k3sLightweight Kubernetes installation (<40MB).Quick and reliable local chart testing.Homepage
k9sGreatly reduced typing of kubectl commands.Navigate and manage cluster resources quickly in a command line interface.GitHub
lensHighly visual management and navigation of clusters.Navigate and manage cluster resources quickly in a standalone desktop application.Homepage
sternEasily follow logs from multiple pods.See logs from a set of GitLab pods together.GitHub
diveExplore container layers.A tool for exploring a container image, layer contents, and discovering ways to shrink the size of your Docker/OCI image. GitHub, GitLab Unfiltered
container-diffExplore container layers.A tool for analyzing and comparing container images.GitHub

Kubernetes cluster

A cloud or local Kubernetes cluster may be used for development. For simple issues, a local cluster is often enough to test deployments. When dealing with networking, storage, or other complex issues, a cloud Kubernetes cluster allows you to more accurately recreate a production environment.

caution
Kubernetes nodes must use the x86-64 architecture. Support for multiple architectures, including AArch64/ARM64, is under active development. See issue 2899 for more information.

Local cluster

The following local cluster options are supported:

Cloud cluster

The following cloud cluster options are supported:

  • GKE - Google Kubernetes Engine, recommended
  • EKS - Amazon Elastic Kubernetes Service

Installing from repository

Details on installing the chart from the Git repository can be found in the developer deployment documentation.

Developer license

A developer license can be used for chart development to test features that are only functional in a licensed environment.

To use a developer license follow the instructions for Enterprise licenses and connect your instance to the Staging Customers Portal.

global:
  extraEnv:
    GITLAB_LICENSE_MODE: test
    CUSTOMER_PORTAL_URL: https://customers.staging.gitlab.com