Now that Solace PubSub+ is available in Helm Hub, it is easier than ever to deploy PubSub+ in a Kubernetes cluster. For users that have Helm installed, it’s a single command. For those not familiar with Helm, it is a CNCF incubator project that bills itself as the “the package manager for Kubernetes” but, it’s really a lot more. If you are familiar with Kubernetes, you will be used to typing kubectl commands to manage your deployments. Helm provides a higher-level interface that helps manage the full lifecycle of applications in Kubernetes.
Helm Hub is a public repository for Helm charts (think of a chart as a customizable Kubernetes template). In the Helm Hub you will find hundreds of charts for all kinds of applications, ready to install. All you have to do to install a chart on your Kubernetes cluster is specify the name of the chart and overrides to the defaults contained in the values.yaml file. Helm will manage all of the dependencies and when you want to make a change, Helm can manage the upgrade of the installation as well.
Helm operates on charts. A chart is a collection of files that allows you to define, install and upgrade a Kubernetes application. The directory structure is defined as follows:
The Solace repo in Helm Hub contains three charts. If you’re familiar with Kubernetes, the contents of the templates directory will look familiar to you. These templates are similar to Kubernetes templates but, Helm allows you to insert bits of logic that when combined with the contents of the values.yaml file by Helm will render a template that can be deployed in Kubernetes. It’s like a template that can be customized at the time of deployment so that one template can be used for multiple deployments. This facilitates sharing because a single chart can be deployed in different circumstances by installing the chart with a custom values.yaml file. You download the chart, modify the values.yaml file to suite and deploy the chart. With a standard Kubernetes deployment, the customizations for each deployment need to be made in individual copies of the templates and if there is a bug in the template, the fix needs to be implemented in each copy. With Helm, the fix is implemented once in the chart and then all of the installations are ready for upgrade.
The Solace repo in Helm Hub contains three charts:
pubsubplus-dev: Deploy a minimum footprint single-node non-HA Solace PubSub+ Event Broker Software onto a Kubernetes Cluster for development purposes
pubsubplus: Deploy a single-node non-HA Solace PubSub+ Event Broker Software onto a Kubernetes Cluster
pubsubplus-ha: Deploy an HA redundancy group of Solace PubSub+ Event Broker Software onto a Kubernetes Cluster
The pubsubplus-dev chart is suitable for installation on a desktop as a part of a development environment. To scale up or add high availability for a QA or production environment, install the pubsubplus or pubsubplus-ha charts. Everything works more or less the same. Helm makes it easy to develop and deploy applications in Kubernetes from development to QA to production.
Now that Solace PubSub+ is available in Helm Hub, users no longer need to take the PubSub+ container and create their own Kubernetes templates. They can simply take the pre-packaged templates (developed by Solace) from Helm Hub and install them. The source code is available should any modifications be required.
There is a companion codelab to go with this blog that will show you how to set up a dev environment and install a pubsubplus-dev chart. The dev environment is setup with Docker Desktop and Helm running on a Windows 10 desktop.
These are the steps that the codelab will walk you through: