The Cluster-api-installer repository creates Helm charts for Cluster-API (CAPI) and its providers, such as Cluster-API-provider-AWS (CAPA), designed for deployment on OpenShift clusters. The MultiClusterEngine operator utilizes these Helm charts to deploy CAPI and CAPA as components of the MultiClusterEngine. For the upcoming release, the Cluster-api-installer repository will include Helm charts for additional Cluster-API providers, such as Cluster-API-provider-Azure (CAPZ) and Cluster-API-provider-Metal3 (CAPM).
CAPI components require the cert-manager operator to generate the necessary certificates. The Cluster-api-installer modifies the CAPI Helm charts to leverage the cert-serve-service (certificate service) that already exists within the OpenShift cluster, instead of relying on the cert-manager operator.
The cluster-api-installer synch the changes happened in the openshift/cluser-api and openshift/cluster-api-provider-aws repos to the chart directory
- Core CAPI provider →
charts/cluster-api
- CAPA - AWS provider →
charts/cluster-api-provider-aws
The synchronization process synchronizes the Kubernetes deployment and creates a Helm chart (used for the Backplane Operator).
The synchronizations are defined in charts/Makefile
:
OCP_VERSION ?= 4.19
BRANCH ?= master
ORGREPO ?= https://github.com/openshift
Where:
OCP_VERSION
... the base for:- Controller image version - used in the Kubernetes deployment
- Helm chart version (version in Chart.yaml)
BRANCH
... the branch from which we will sync the changesORGREPO
... source repository URL
Then (for PROJECT
in cluster-api
cluster-api-provider-aws
):
- The Git repository
$ORGREPO/$PROJECT
will be cloned intoout/$PROJECT
, and the$BRANCH
will be checked out into theout
temporary directory. - The
src/$PROJECT.yaml
file with the source objects (before transformation - see below) will be created. - The synchronization of CRDs and Helm chart templates will begin, and the necessary files will be created/updated in the
charts/$PROJECT/crds
andcharts/$PROJECT/templates
directories.- Synchronization is performed using Kustomize transformations defined in the
config/$PROJECT
folder.
- Synchronization is performed using Kustomize transformations defined in the
- The version in
charts/$PROJECT/Chart.yaml
and theimage.tag
incharts/cluster-api/values.yaml
will be updated based on$OCP_VERSION
. - You can view the changes (using
git status
) in:- The sources before transformation - in the
src/$PROJECT.yaml
file. - The target Helm charts in the
charts/$PROJECT
directory.
- The sources before transformation - in the
There are also GitHub workflows for synchronization.
See this documentation if you want to add a new provider.
- To sync:
make
- This will sync all charts.- You can view the changes using
git status
after a successful command. - To speed up testing (skip
git pull ...
), use:export SKIP_CLONE=true; make
- You can view the changes using
- To use Docker, run:
make build-docker
- The result should be the same as
make
. - A Docker container is used for a more unified build environment.
- Use this if you encounter issues with the standard
make
command.
- The result should be the same as
- To check chart deployment:
make test-charts-crc
- To delete CRC before testing:
export CRC_DELETE=true; make test-charts-crc
- To delete CRC before testing:
- To clean all temporary files:
make clean