Access the Kubernetes Dashboard Grafana

Prerequisites

  • Kubernetes 1.19+

  • Helm 3+

Get Helm Repository Info

sudo helm repo add prometheus-community https://prometheus-community.github.io/helm-charts
sudo helm repo update

Install Helm Chart

sudo helm install [RELEASE_NAME] prometheus-community/kube-prometheus-stack

Once this is done, you can verify if the deployment is running.

Now, to expose the dashboard for external access, you need to change the service's ClusterIP type to NodePort. You can do this with an ingress or by editing the file:

sudo kubectl edit service grafana

After making the change to NodePort, save and close the file. When performing a new query, you'll notice that the type has changed, and a new port has been added.

Once this is done, you should have access to the dashboard through the public IP of your instance, along with the released port.

Default credential: user: admin pass: prom-operator

When you access the dashboard, you will find it ready for monitoring.

When installing Grafana, several default dashboards are included. You can customize them or create your own dashboard as needed.

Last updated