Public Cloud > Container > Aruba Managed Kubernetes > Activating the autoscaler

04 Activating the autoscaler

Requirements

To activate the autoscaler within the Kubernetes cluster, make sure you have:
  • access to the cluster via kubectl for verification or debugging operations (optional but recommended);
  • Helm installed locally (installation guide);
  • a Node Pool with autoscaling enabled;
  • an active network connection to the cluster (VPN or private access if the cluster is not public);
  • a valid Client Credential, consisting of a Client ID and Client Secret.
These requirements ensure that the autoscaler can be installed and communicate correctly with the infrastructure.

Where to find the required parameters

To install the autoscaler correctly:
  • access the cluster details page;
  • locate the box dedicated to activating the autoscaler;
  • select View precompiled chart;
  • the Helm chart window displays all the required information:
    • for example:
      $ helm repo add arubacloud https://arubacloud.github.io/helm-charts/
      $ helm repo update

      $ helm install my-release arubacloud/cluster-autoscaler -n kube-system \
          --set 'arubaClientID'='ClientID' \
          --set 'arubaClientSecret'='ClientSecret' \
          --set 'arubaProjectID'='6939330d7e7205c3680afc91' \
          --set 'arubaClusterID'='6939b4cd376246c007db0dff' \
          --set 'arubaRegion'='ITBG-Bergamo' \
          --set 'image.tag'='v1.32.3'
  • specifically:
    • ClientID is the Client ID of the Client Credential that you must enter in place of the ClientID value;
    • ClientSecret is the Client Secret of the Client Credential that you must enter in place of the ClientSecret value;
    • Project ID is the ID assigned to the project (the value is already filled in);
    • Cluster ID is the ID assigned to the cluster (the value is already filled in);
    • Region is the region where the cluster is located (the value is already filled in);
    • image.tag is the Kubernetes version (the value is already filled in).
To protect the sensitive data of the Client Credential (Client ID and Client Secret), we recommend storing them as Kubernetes Secrets in the kube-system namespace. This allows the autoscaler to use them without entering them directly in commands or configuration files.

Installing the autoscaler with Helm chart

To complete the installation of the autoscaler in the Kubernetes cluster, open the terminal and run the commands in the precompiled chart available on the cluster details page.
For additional information or to customise the configuration, see the official documentation on GitHub:
https://github.com/Arubacloud/helm-charts/blob/main/charts/cluster-autoscaler/README.md

Checking the deployment status

After installation, you can check that the autoscaler is active and running correctly in the cluster.
Open the terminal and run:

k get po -A

In the kube-system namespace, locate the pod <pod-name> (with a name similar to aca-arubacluster-autoscaler-...).
It must have the Running status, for example:

...
kube-system     <pod-name>      1/1     Running
...

To monitor its activity in real time, you can view the logs with:

k logs -f -n kube-system <pod-name>

What to do if it does not work

If, after installation, the autoscaler does not start or does not scale as expected, check the following:
  • the cluster-autoscaler pod in the kube-system namespace has the Running status;
  • the minimum and maximum values for the Node Pool are configured correctly;
  • all pod manifests include the resources.requests parameters for CPU and memory;
  • the network allows the autoscaler component to access the cloud APIs (including authentication where required);
  • you can analyse the pod logs for further details:

    kubectl logs -n kube-system <nome-pod>