The CLAMP Kubernetes Participant performs the helm Helm chart installation and LCM for k8s Kubernetes (K8S) microservices that take part in Control looploops. It implements Participantthe participant-Intermediary API to receive events from DMaap the CLAMP runtime and then interacts with Helm CLI. It acts as a wrapper around the Helm Cli CLI to manage helm Helm charts and K8s pods deployed in the cluster.
Helm 3 overview:
In Helm3, helm cli the Helm CLI acts as an interface for towards a Kubernetes cluster, and allows the user to deploy and manage helm charts. It also supports configuring configuration of multiple chart repositories to for the helm client and enables access the to charts from those repos for installation of K8S microservices. The repositories can be a local chart server servers running on the same machine as well a or third party chart server servers running elsewhere. The URL of the chart achart server can be configured on the helm Helm repo list to permit access the hosted helm charts. User can add a repository and push helm charts under the repository via helm cli to Helm charts hosted in those repos. Users can add repositories and push Helm charts to the repositories via Helm CLI commands.
Example: configured Configured chart repos and the available charts are listed via helm cli:the Helm CLI
CLAMP Kubernetes Participant Architecture in Istanbul:
Prerequisites for kubernetes Kubernetes participant:
- Kubernetes cluster running.
- Helm cli CLI running.
- Operator Currently, the operator is expected to either store the helm Helm charts in any of the configured helm Helm repositories via helm cli command (or) the charts should be kept Helm CLI commands or ensure that the charts are available on the local storage directory of kubernetes-participant. (This directory is a preconfigured path specified on the participant config that acts as a local chart repository).
Note: Incase of containerization of kubernetes participant in When the Kubernetes participant is containerized in the upcoming release, the kubeconfig file of the required kubernetes cluster should be copied to the k8s-participant's docker container in order to make helm cli the Helm CLI work with the external cluster outside.
Drawio | ||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
In the Istanbul release, the CLAMP Kubernetes participant in control loop supports supports the following methods for installation of helm charts in below ways :
- Install Installation of a helm Helm chart that is present in the same local file system as where the kubernetes participant is hosted.
- Install Installation of Helm charts from the helm Helm repositories that are configured on the helm Helm client.
The CLAMP Kubernetes - participant acts as an interface between DMaap and a mediator between the CLAMP runtime and the Helm Client.
While commissioning the a control loopsloop, the helm Helm chart parameters are passed via TOSCA template to the control loop runtime database. And when the control loop is instantiated, kubernetes-the Kubernetes participant receives control loop element update event from DMaap, it the CLAMP runtime. It then invokes the helm Helm client running on the host machine to install the corresponding helm Helm charts associated with the affected control loop elements.
...