Portainer News and Blog

Create and Manage a MicroK8s cluster with Portainer

Written by James Traxler | September 5, 2023

In Portainer Business Edition 2.18, we introduced the MicroK8s cluster creation feature, allowing you to spin up a cluster on your existing infrastructure.

In BE 2.19 we’ve added the ability to perform various cluster management operations – once you have your MicroK8s cluster up and running.

The idea behind Canonical’s MicroK8s is to provide a lightweight Kubernetes install – running in as little as 540MB of memory. However, do note that, to accommodate workloads, a system with at least 20GB of disk space and 4GB of memory is recommended.

At Portainer, we wanted to make the process of installing and managing a MicroK8s cluster achievable with just a few clicks. And that’s what we’ve done!

List of features

The MicroK8s functionality that we now offer gives you the ability to perform the following:

  • Create a cluster on existing machines
    • Bring your own machines (e.g. VMs) – note that, at present, you’ll need Ubuntu 20.04 LTS or above (although other distributions and versions may work)
    • MicroK8s will be installed and a cluster created – you can specify from 1 to 100 nodes
    • Control plane nodes and worker nodes can be separately denoted
  • Horizontally scale a cluster up or down
    • Add or remove nodes at will – they’ll even be set up with any addons you already have enabled on other nodes in your cluster
  • Upgrade the version of the cluster
    • At the time of writing, we allow clusters with MicroK8s versions 1.24 to 1.28 and we plan to support new versions as they’re released
  • Delete the cluster
    • You can optionally revert your machines back to the state they were in before you created a cluster – ready for you to reuse
  • Enable/disable addons
    • A small subset of required addons are automatically enabled
    • For any others, you can choose from core and community addons
    • Specify the addons you want enabled at cluster creation, or, once your cluster is up and running, enable or disable addons at will
    • For those addons that allow it, specify any arguments that you want to be used
  • Connect to any node in the cluster via SSH console
    • It’s an easy way for you to reach the command line – in case there are any tasks you want to perform that our UI doesn’t cover
  • Run a status check on any control plane node of the cluster
    • This gives you a summary of key information on a node

You can also see the usual information that we show for any Kubernetes cluster, such as the IP addresses and types of the nodes, whether they’re up or down, node metrics and so on.

Run-through

There’s a run-through of our feature set in our MicroK8s on Portainer YouTube video – enjoy!

Note: Considering the amount of technology under the hood, there are a few gotchas that you’ll need to be careful of, so make sure you take a look at our MicroK8s Known Issues KB article.

Try Portainer with 3 Nodes Free

If you're ready to get started with Portainer Business, 3 nodes free is a great place to begin. If you'd prefer to get in touch with us, we'd love to hear from you!