Octant and Dashboard for Kubernetes

Lubomir Tobek
3 min readNov 22, 2023

--

“Octant is an open source developer-centric web interface for Kubernetes that lets you inspect a Kubernetes cluster and its applications.”

Octant is a web application that talks to your Kubernetes clusters and provides an easy-to-read dashboard for the objects in your clusters.

Visualize your Kubernetes workloads, Source of an image: octant.dev

For simple deployment, we will use the simple kubernetes environment from the previous post, and we will look at the primary view.

Source: https://octant.dev/

Features

Resource Viewer
Graphically visualize relationships between objects in a Kubernetes cluster. The status of individual objects are represented by color to show workload performance.

Summary View
Consolidated status and configuration information in a single page aggregated from output typically found using multiple kubectl commands.

Port Forward
Forward a local port to a running pod with a single button for debugging applications and even port forward multiple pods across namespaces.

Log Stream
View log streams of pod and container activity for troubleshooting or monitoring without holding multiple terminals open.

Label Filter
Organize workloads with label filtering for inspecting clusters with a high volume of objects in a namespace.

Cluster Navigation
Easily change between namespaces or contexts across different clusters. Multiple kubeconfig files are also supported.

Plugin System
Highly extensible plugin system for users to provide additional functionality through gRPC. Plugin authors can add components on top of existing views.

Source: https://github.com/vmware-archive/octant

I used Photon OS for the underlying operating system.

I used these simple commands for deployment (Of course other installation methods are also available):

root@k8-worker-node [ ~ ]# wget https://github.com/vmware-tanzu/octant/releases/download/v0.24.0/octant_0.24.0_Linux-64bit.tar.gz

root@k8-worker-node [ ~ ]# tar -xvzf octant_0.24.0_Linux-64bit.tar.gz
root@k8-worker-node [ ~ ]# cd octant_0.24.0_Linux-64bit/
root@k8-worker-node [ ~/octant_0.24.0_Linux-64bit ]# ./octant

Dashboard is available at http://127.0.0.1:7777

Octant uses below environment variables to set the access:

OCTANT_ACCEPTED_HOSTS — Local IP address of the machine it runs on
KUBECONFIG — Path to the kubeconfig file

OCTANT_LISTENER_ADDR — Listening IPs and the port (0.0.0.0 — “All IP addresses of the local machine”)

Method Exporting Environment Variables (access from local host to VM with IP: 192.168.212.140, with Octant deployment):

OCTANT_ACCEPTED_HOSTS=$(curl http://192.168.212.140/latest/meta-data/local-ipv4) KUBECONFIG=~/.kube/config 
OCTANT_LISTENER_ADDR=0.0.0.0:7777 octant

In the previous post, I created a simple unmanaged cluster with name “tce-umng-cl” and a mini “nginxdeployment”:
https://medium.com/@lubomir-tobek/deploying-tanzu-tce-unmanaged-cluster-using-docker-896e886fd454

Here are some of my illustrative screenshots:

Octant Demo

The Octant K8s UI won’t be for everyone, but it’s a lovely addition to your tool portfolio if you’re exposed to Kubernetes. It’s a good idea to offer users an overview of the environment who don’t know about Kubernetes. Octant is linked to the kubeconfig file; all you need to do to give someone access is create a profile and apply the correct permissions with Role Based Access Control.

--

--