A Quick Guide To Monokle

A open-source desktop UI to manage Kubernetes manifests

A Quick Guide To Monokle

What is Monokle and why use it?

When working with Kubernetes, it becomes a challenge to manage our manifest when we have lots of resources present. Comes into picture Monokle, a tool by Kubeshop which allows us to easily manage and debug our manifest by providing an interactive UI, making it easier to navigate through our k8s manifest.

Installation and Setup

  • Intalling Monokle is pretty straightforward. Just visit the Official Site and simply download the setup suitable for your OS.

1.png

  • If you don't have any YAML files for Monokle to navigate through, then you can get them from the Documentation provided by Monokle or simply clone these two repositories where we will use Kustomize (A Kubernetes configuration transformation tool that enables you to customize untemplated YAML files, leaving the original files untouched. To know more, visit here) and Helm Charts (A Collection of files that describe a related set of Kubernetes resources. Visit here To know more) when navigating. Just run the following commands inside your terminal :
    git clone https://github.com/argoproj/argo-rollouts.git
    
    git clone https://github.com/emissary-ingress/emissary.git
    

    Navigating through manifests

    When you first boot up the Monokle, you will be asked to select the project you want to work with, but here we will simply select the folder containing the k8s resources that we have just cloned from GitHub.

2.png Firstly we will browse the manifest folder under the argo-rollouts folder. After this, you will see all the k8s resources as in the following image :

3.png

Now you don't have to worry about all those YAML files on the left side under the "File Explorer" tab since you are not working with Kubectl commands in which you need to write (or modify) all those lines you see on the Editor tab, which are a lot! So you see how Monokle is allowing us to manage and debug our files by providing a High-Level view.

Previewing output of any YAML file

You can also preview the output of any YAML file by clicking on the preview button shown next to your YAML file (in this example, it's "dashboard-install") under the "Kustomization" tab.

4.png

After that, you will have the output of that particular file as shown below:

5.png

Know the relations in between multiple k8s objects

Now let's browse the helm chart under the emissary folder that we had cloned from GitHub. You will be able to see all the workloads present there. You can find out which workload is attached with which one by simply hovering over that resource, allowing you to see any incoming or outgoing links for that particular workload.

6.png As you can see in the example above, for that particular deployment, we have a service attached to it named "quote". So this too is one among the many amazing features of Monokle where you can find the relations between multiple k8s objects

Making changes in k8s objects

We can simply make changes in our Kubernetes workloads via it's interactive UI, without even working with the YAML syntax.

7.png

As you see in the image, currently the replica is set to 1, let's try changing it to 4 which can be done in the "Form" section under the "Editor" tab.

8.png

Now, these changes are reflected in your YAML file and further you can deploy those changes to your cluster by simply clicking on the "Deploy" button shown next to the "Editor" tab.

9.png

Check Documentation Of Any Resource

You can also open the documentation of any resource type in your external browser by simply clicking on the small book-like icon, shown under the "Editor" tab.

10.png

Creating a Resource

You can even create a resource of any kind in just a few clicks and again by not working with the YAML syntax. Simply just click on the "+" icon shown next to the "Navigator" tab and then define your resource.

11.png

Here you can create any kind of resource, for instance, a Service named "my-quote" and further can deploy it to the cluster.

12.png

Cluster Compare

This functionality allows us to easily compare our cluster resources by providing an interactive-UI and is a great way to do things like deploying local resources to your cluster running on the cloud or replacing some resources with others in your cluster. Do check out this short video by Kubeshop to get get a better idea of the workflow

13.png

Resources