Version: v1.8

Air-gapped Installation for Addon

If your environments don’t have network access to https://addons.kubevela.net or https://github.com/kubevela/catalog, this guide will demonstrate how to install in the air-gapped environment.

Generally, you should git clone the repo which contained the addon configuration, you can specify a local addon directory when enable an addon for installation. While you should make sure all container images or helm charts are replaced by your private registry.

You can follow these steps as an example.

  1. Git clone the catalog repo to download these addon files. You can find all community addons in subdirectory ./addons/ and experimental addons in subdirectory ./experimental/addons.
  1. git clone https://github.com/kubevela/catalog

If you want to self-host addon catalog, refer to Sync addon catalog to your ChartMuseum instance

  1. Sync the dependency container images in the addon to your private image registry, the sync command can be as following:
  1. $ docker pull fluxcd/helm-controller:v0.11.1
  2. $ docker push <your repo url>/fluxcd/helm-controller:v0.11.1
  1. Parts of addons may rely on helm charts, e.g. terraform addon. You should sync these helm charts to your private chart registry.
  1. $ helm repo add vela-charts https://charts.kubevela.net/addons
  2. $ helm repo update
  3. $ helm pull vela-charts/terraform-controller --version 0.3.5
  4. $ helm push terraform-controller-0.3.5.tgz <your charts repo url>

You can use ChartMuseum addon to build your private Helm Chart registry and hold these Charts. Please refer to Sync Helm Charts to your ChartMuseum instance for complete instructions and usage examples.

  1. Modify the values of addon by referring to your own image/chart registry. You can find all images/charts dependency in the files of subdirectory resources/, just modify the configuration. For example, you can modify the fluxcd addon files addons/fluxcd/resources/deployment/helm-controller.yaml the deployment object’s field spec.sepc.containers[0].image to your own image repo.

  2. Use vela cli to enable an addon with specify a local addon dir to install offline.

  1. $ vela addon enable /your/local/addon/directory

Here’s a list about images or helm charts of all community addons that should be synced for air-gapped installation.

The image versions below can be outdated. You should check the addon files to find out the latest version used in addons.

You need sync these images to your own image registry, and modify the related addon files to reference you own registry.

Imagesfiles
fluxcd/helm-controller:v0.11.1fluxcd/resources/deployment/helm-controller.yaml
fluxcd/image-automation-controller:v0.14.0fluxcd/resources/deployment/image-automation-controller.yaml
fluxcd/image-reflector-controller:v0.11.0fluxcd/resources/deployment/image-reflector-controller.yaml
fluxcd/kustomize-controller:v0.13.1fluxcd/resources/deployment/kustomize-controller.yaml
fluxcd/source-controller:v0.15.3fluxcd/resources/deployment/source-controller.yaml
Imagesfiles
quay.io/open-cluster-management/registration-operator:latestocm-cluster-manager/resources/operator/operator.yaml

There is no need to modify the addon files for enabling this addon, you only need to sync these images and enable this addon with repo args to reference your own registry.

Images
oamdev/vela-apiserver:v1.2.3
oamdev/oamdev/velaux::v1.2.3

eg:

  1. $ vela addon enable addons/velaux/ repo=<addon-registry-url>
  1. Sync the image oamdev/terraform-controller:0.3.5 to your own images registry.
  2. Dowload the terraform helm chart.
  1. $ helm pull https://charts.kubevela.net/addons/terraform-controller-0.3.5.tgz
  1. Extract the chart and modify the values.yaml change image.repository to your own image registry.Then push it to your helm chart museum.
  2. Modify the addon file terraform/resources/terraform-controller.cue change output.properties.url to your chart museum’s url.

  3. Sync the image oamdev/vela-rollout:v1.6.4 to your own images registry.

  4. Dowload the rollout helm chart.
  1. $ helm pull https://charts.kubevela.net/core/vela-rollout-1.3.0.tgz
  1. Extract the chart and modify the values.yaml change image.repository to your own image registry.Then push it to your helm chart museum.
  2. Modify the addon file rollout/resources/rollout-controller.cue change output.properties.url to your chart museum’s url.

Last updated on May 6, 2023 by Tianxin Dong