Add-Ons in Cluster Blueprints - Rafay Product Documentation

Custom Add-Ons

The first part of defining your cluster blueprint or using the default blueprints in the system involves making a decision on what software you want present in your Kubernetes clusters. An add-on is defined as a software component that runs inside a cluster. All cluster blueprints are comprised of one or more software add-ons.

The platform supports two types of add-ons:

  1. Managed System Add-Ons: These are software components that are provided by the system so that you don't need to configure or package them yourself.

Some of these today include:

To read more about what the platform has available, check out the Managed Add-Ons documentation.

  1. Custom Add-Ons: Custom Add-Ons are meant to be software components that are meant to be cluster-wide services or operate invisibly in the background.

This could be tied to things such as:

Infra admins can assemble one or more add-ons to create a cluster blueprint.

What types of custom add-ons are available and when should I use each?

The following lists the add-on types available and when an admin should use that add-on type. It comes down to either using add-ons that are pre-packaged from a catalog or packaging your own.

Refer Catalog for more information

Helm Versions

The controller supports Helm packages in both Helm 2 and 3 package formats. With Helm 3, the Controller acts like a Helm 3 client and does not have to parse and break down the chart down to its atomic k8s resources for deployment. Support for Helm 2 in workloads is deprecated and is only meant to be used for legacy charts that are incompatible with Helm 3. Read more about Helm 2 End of Life.

Can I mix and match add-on types in a blueprint?

Yes. You can have different types of add-ons, some ranging from managed add-ons to custom ones as well having different types of custom add-ons.

How Are Add-Ons Scoped?

By default, add-ons are NOT "Org wide" resources and are scoped to a project to guarantee a "hard" isolation boundary. All clusters in a given project can use/leverage blueprints based on the add-ons in the Project.

Who can create and manage add-ons?

The lifecycle of add-ons is managed by users with an "infrastructure administrator" role or "organization administrator" role. See the roles documentation for more details.

What are the pre-requisites for creating an add-on?

Is there a way for me to group add-ons together?

Yes, you can accomplish this via labels for add-ons. See below for more on how to leverage this functionality.

What mechanisms are available for me to create add-ons?

Add-Ons can be created in a specific project via multiple mechanisms

  1. Using the Web Console
  2. Using the RCTL CLI Utility
  3. Programmatically using the REST API
  4. Terraform

Creating a Custom Add-On

The following steps will leverage the Web Console. Following the RCTL CLI Utility doc or REST API documentation if you want to use those mechanisms.

Catalog App Type

Now that we have created an add-on, you can manage it, including defining values.yaml file by creating a new version.

Selecting the Type

Artifact Sync Options

Depending on the selected package type, different artifact sync options are available:

Example 1: In the example below, we are creating an add-on for "kubeless" which is packaged as a Kubernetes yaml file. We want to deploy this into a namespace called "kubeless" and we plan to provide the artifact as a k8s yaml file.

Example 2: In the example below, a new add-on is being created using Kustomize, where the customized manifests are provided as a zipped folder containing the required base and overlay structure.

Managing Custom Add-Ons

Now that you have created the add-on, the next step is to define a version for the add-on which is used for managing certain configurations. Multiple versions/updates of the add-on may be required during the life of an add-ons. Users can manage multiple versions of add-ons. At least one add-on version is required meaning the user will be prompted to "create" a new version the first time an add-on is created.

K8s YAML

Uploading Your Own File

Pulling Files From Git Repository

Pulling File From URL

In the example below, the add-on named demo-weburl uses the K8s YAML package type and Pull file from URL artifact sync option. The YAML file is fetched directly from the specified GitHub raw content URL, and the add-on will be deployed in the namespace ns-528327659.

Once a new version is created, the file can be viewed by clicking the link provided, as shown below.

Helm

It's possible to have multiple values.yaml files for the same helm chart. They are processed and applied to the chart in the order they are uploaded.

Uploading Your Own File(s)

Pulling Files From Git Repository

  1. Value Path: This involves specifying the values.yaml path(s). It's possible to have multiple values files for the same helm chart. They are processed and applied to the chart in the order they are uploaded.
  1. Git Path: A Git Path can be optionally specified to point to a values.yaml file. This file can either serve as your core values.yaml file or specifically as an override to override certain values defined in the Helm charts that come from the value path.

The following example below shows when the specified file acts as your core values.yaml file:

The other example below shows when the specified file acts as an override to certain values configured in the value path:

Pulling Files From Helm Repository

  1. Upload: You can upload the values.yaml files from a local machine.
  1. Override From Git Repository: You can also specify a values.yaml file from a Git Repository and have that act as an override.

Advanced Helm Options

Support for advanced Helm options is available under "Helm Options".

Helm Option Description
Atomic If enabled, upgrade process rolls back changes made in case of failed upgrade. The --wait flag will be set automatically if this option is enabled. It will wait for as long as the configured timeout duration
Cleanup on Fail Allow deletion of new resources as part of the upgrade when upgrade fails
Disable Open API Validation If enabled, the installation/upgrade process will not validate rendered templates against the Kubernetes OpenAPI Schema
Force Force resource updates through a replacement strategy
Max History Limit the maximum number of revisions saved per release, default value is 10
Description Add a custom description
No Hooks If this option is enabled, pre/post hooks are disabled
Render SubChart Notes If enabled, subchart notes are rendered along with the parent
Reset Values When upgrading, reset the values to the ones built into the chart
Reuse Values When upgrading, reuse the last release's values
Set String set STRING values
Skip CRDs If this option is enabled, no CRDs will be installed. By default, CRDs are installed if not already present
Timeout Time to wait for any individual Kubernetes operation (like Jobs for hooks), default is 5m0s
Wait If enabled, will wait until all Pods, PVCs, Services, and minimum number of Pods of a Deployment, StatefulSet, or ReplicaSet are in a ready state before marking the release as successful. It will wait for as long as the configured timeout duration
Wait for Jobs When configured, it will wait until all Jobs are finished before marking the release as successful. It will wait for as long as the configured timeout duration

Kustomize

Kustomize provides a Kubernetes-native approach for defining and managing add-ons by building manifests from a set of YAML files and applying configuration transformations. It allows managing environment-specific variations, such as production, staging, or development, within a single packaged structure.

Uploading Your Own File(s)

Example Folder Structure

my-kustomize-folder/
├── common/
│   ├── deployment.yaml
│   ├── service.yaml
│   └── kustomization.yaml
├── dev/
│   └── kustomization.yaml
├── staging/
│   └── kustomization.yaml
└── production/
    └── kustomization.yaml

In this example:

In the example shown, a new version named v1_production is created by uploading a zipped folder (kustomize_config.zip) containing the configuration files, with the deployment path set to production.

Pulling Files From Git Repository

This method allows users to maintain and build YAML manifests (for example, pod.yaml) directly from a Git repository, applying environment-specific configurations based on the specified Kustomize path.

This approach offers a Kubernetes-native alternative to Helm-based add-ons, supporting flexible configuration and deployment workflows.

Grouping Add-Ons Via Labels

Many times, there will be a need to group specific add-ons in a single bucket for organization and management purposes. For example, you may want to group all security add-ons into one specific bucket. Or maybe there's a specific set of pre-requisite add-ons that have to be deployed to every cluster blueprint.

To facilitate this, you can use the add-on labels functionality which allows you to:

Creating and Assigning Labels To Add-Ons

In order to assign labels to an add-on:

View/Download Add-On Artifacts

If the files were uploaded manually via the controller, artifacts for the current or previous versions of the add-on can be retrieved. This is applicable for the following types of add-ons:

Artifact downloads are not supported natively when Pull Files From Repository is selected as the Artifact Type as those files can be retrieved directly from the repo, including checking out older commits to get access to historical artifacts.

Deleting An Add-On

If an add-on is not required anymore, the admin may wish to delete it from the Project.

Debugging Add-Ons

Many times, infrastructure admins will need to debug add-ons to validate deployments, check the status, and more. The following mechanisms are available to debug add-ons:

Infrastructure admins or organization admins can view the status of each add-on using the cluster dashboard on the Web Console. In addition,

Drift Detection and Blocking

The configuration for add-ons deployed to remote clusters as part of a cluster blueprint are protected from manual, out of band changes (inadvertent or malicious). The k8s mgmt operator will detect and block any attempts to perform manual changes using Kubectl or Helm.