Learn KOP - Utilize Cluster Overrides - Rafay Product Documentation

Part 2: Utilize

This is Part 2 of the exercise that will focus on using cluster overrides to customize add-ons.


What Will You Do

In part 2, you will:


Step 1: View Replica Count

In this step, we will view the current replica counts for the previously deployed add-ons.

kubectl get deployments -n overrides-namepsace

You will see that both the YAML and HELM deployments each have one pod.


Step 2: Create YAML Cluster Override

In this step, we will create a cluster override for the YAML based add-on which will increase the number of pods in the add-on for a specific cluster. The override will not be applied until the blueprint is applied to the cluster.

Navigate to the "Selectors" section of the window.

Navigate to the "Override Configuration" section of the window.

apiVersion: apps/v1
kind: Deployment
metadata:
  name: nginx-yaml
patch:
- op: replace
  path: /spec/replicas
  value: 3

Step 3: Create Helm Cluster Override

In this step, we will create a cluster override for the Helm based add-on which will increase the number of pods in the add-on for clusters with a specific label. The override will not be applied until the blueprint is applied to the cluster.

Navigate to the "Selectors" section of the window.

Navigate to the "Override Configuration" section of the window.

replicaCount: 4

You will now see both the YAML and Helm overrides.


Step 4: Apply Blueprint

In this step, we will apply the blueprint to an existing cluster. This time, the cluster overrides will be used which will update the pod counts for the add-on deployments.

The blueprint will begin to be applied to the cluster.

The blueprint is now applied to the cluster.


Step 5: View Replica Count

In this step, we will view the current replica counts for the previously deployed add-ons. The pod counts for the add-ons will be higher this time as the cluster overrides were in place.

kubectl get deployments -n overrides-namepsace

You will see that both the YAML and Helm deployments each have the same pod count as defined in the cluster overrides.


Recap

Congratulations! You have successfully used cluster overrides to customize the add-on replica count for both YAML and Helm based add-ons.