Purple pattern background

Cluster API driver for OpenStack Magnum

Mohammed NaserMohammed Naser

We're happy to announce that we're making available the Cluster API driver for OpenStack Magnum which will allow you to make use of the latest developments of the active Cluster API community while maintaining the existing feature set and existing ecosystem around Magnum.

The biggest reason behind building this was to avoid relying on the code that managed the life cycle of Kubernetes clusters which has become cumbersome to maintain and slowed down since more and more users have pivoted towards other ways of deploying Kubernetes. Instead, this will simply make Magnum an API server and rely on the fast moving, maintained Cluster API on top of supported operating systems such as Flatcar or Ubuntu.

The Cluster API is a open source project which lives under the Kubernetes community which was created to maintain a standardized methodology of deploying Kubernetes clusters on different environments, with different providers (think implementations) of it that can interact with different cloud environments, including OpenStack.

OpenStack Magnum is a project that started very early when containers were early and there were many different orchestration technologies, back then, it had full support for Docker Swarm, Mesos & Kubernetes. Nowadays, it's mainly used to drive Kubernetes deployments on top of OpenStack.

For a bit of history, Magnum was created way before there was any standardized way of deploying Kubernetes. This meant that much of the code was a combination of shell scripts and Heat templates that together managed to deliver a Kubernetes cluster. However, it was a bit painful to deal with as Kubernetes grew.

The pain came from the fact that every time a new release of Kubernetes went out, a whole bunch of changes needed to be made. We also needed to coordinate underlying operating system concerns, with major changes over the years such as the deprecation of Fedora Atomic Host, the moving to Fedora CoreOS.

There are also a lot of 'artifacts' of ways that Magnum does things such as running the Kubelet inside of a container which is not something supported upstream, as well as other wild historical things such as running API services in podman, but running the workloads inside containerd.

The community has been super receptive at continuing to maintain things, but at some point, we believe that we've hit a bit of a wall at this point. There's a huge sunk cost in continuing to maintain the existing Magnum codebase when there are other projects that are working more effectively at doing the same.

Cluster API (and all the projects around it) demonstrate a great point of how open source collaboration can work. All of the different users of the cloud platforms realized that the deployment process once you have machines is pretty much the same. Therefore, the community came up with a simple but effective concept: Cluster API will encompass all the common bits which include deploying the actual software, cluster life-cycle, etc. while the different providers will focus on supplying the underlying infrastructure for Cluster API.

So, there are many providers for different providers like OpenStack, VMware, AWS and many others. Once a new cluster is created, Cluster API goes out to the providers to request the VMs, once the VMs are created by the providers, it'll take over the operations. With this, it means that the providers essentially only have to maintain the code that spins up the infrastructure, and the collective group can work together on making the best cluster life-cycle tooling that all providers benefit from. There have been many features built-out such as autoscaling, autohealing and much more to come.

Within Atmosphere, our deployment tooling for OpenStack, we already have a Kubernetes cluster which we use for deploying OpenStack. This means that adding Cluster API controllers to the mix is trivial since it's already there, and the implementation would essentially mean that we just need to convert Magnum API objects into Cluster API native objects and manage the life cycle for that, which significantly simplifies the Magnum driver.

We're announcing this early so that we can hopefully get more interest into the implementation. We're happy to see how all the different open source projects can be working together to produce a fantastic result. You can get started by trying out the Cluster API with a DevStack installation, and we'll be adding native support for the Cluster API inside Atmosphere shortly so it'll be available out of the box.

Share on social media