Docker container technology has taken the world of application development by a storm by simplifying and speeding the development, deployment and maintenance of server-side applications.
What started as a way to partition and manage the resources single host computer (or VM), the technology has now matured to the management of containerized workloads across a cluster of hosts/VMs.
Among the most popular container cluster managers are Kubernetes (originally from Google), Apache Mesos and Docker Swarm (from the creators of Docker). Each cluster management technology has something unique and different to offer.
- Apache Mesos is mature and can also run non-containerized workloads (such as Hadoop).
- Kubernetes tends to be opinionated. It offers little customization (for now) and networking can be a challenge. But it is moving fast and the defaults can be a quick way to get started.
- Docker Swarm is from Docker, Inc and offers the familiar Docker (single-host) API. It is the easiest to get started with, but also the least mature (as of this writing).
As a developer / infrastructure architect, it can be tough to decide on the right technology for your needs. The only way to evaluate them is to actually deploy them in your infrastructure and test them with your workloads. This isn’t easy for several reasons:
- While the cluster managers manage the containerized workloads, somebody else has to manage the cluster of VMs — deploy the cluster manager, scale the cluster and monitor the cluster.
- Cluster managers also rely on a host of supporting infrastructure which also needs to be managed: Mesos requires Apache Zookeeper, Kubernetes requires etcd.
- Your infrastructure is probably a hybrid of clouds and datacenter : each cluster manager has a different set up script for different clouds and hypervisors.
- You need to manage / orchestrate non-containerized infrastructure like a Citrix Netscaler Loadbalancer in concert with the cluster manager.
Citrix Lifecycle Management (CLM) is an application lifecycle manager that can help you deploy, scale and maintain these cluster managers: either in your datacenter or in the Cloud. CLM has blueprints that can get you up and running with these cluster managers very quickly:
The picture below shows all three cluster managers deployed on the same pool of Citrix XenServer hosts. It is worth noting that Citrix XenServer itself uses clustering technology to group a related set of hypervisors!
You can see that I’ve installed the XenServer Docker Supplemental Support Pack to get a view of the containers running inside the various clusters.
The next figure below shows a Kubernetes cluster and a Mesos cluster running on AWS — also launched, configured and monitored by CLM — also using the same blueprint used to launch the clusters on XenServer.
In all cases, all it takes is to use the published blueprints in Citrix Lifecycle manager and give a few inputs. You can launch these before your lunch break and come back to have a productive day hacking on cluster managers. CLM takes over the undifferentiated heavy lifting of setting up these cluster managers, letting you focus on your workloads!
For those developers who are unable to create VMs or cloud instances, CLM offers the ability to deploy these clusters on pre-created VMs / baremetal hosts.
- You may have noticed a Netscaler Virtual Appliance (VPX) in the list of virtual machines running on XenServer. That instance was deployed by CLM as well. Once deployed, the VPX instance can be used to load-balance your containerized workloads.
- The blueprint steps contain several goodies that can be re-used in other contexts. For example, there is a step that installs Apache Zookeeper. Another step helps you install docker-engine reliably in a VM.
I hope this note helps you get started in your clustered container story. Let me know in the comments if you have any ideas / questions / feedback. Happy clustering / container-ing!