Task - 5 DevOps Assembly Lines

Prathmesh Mandve
3 min readJul 25, 2020

Task Overview

Integrate Prometheus and Grafana and perform in following way:

  1. Deploy them as pods on top of Kubernetes by creating resources Deployment, ReplicaSet, Pods or Services.
  2. And make their data to be remain persistent.
  3. And both of them should be exposed to outside world.

In this task we are going to use Kubernetes, Prometheus and Grafana.

About Kubernetes :

Kubernetes (K8s) is an open-source system for automating deployment, scaling, and management of containerized applications.

About Prometheus :

Prometheus, a Cloud Native Computing Foundation project, is a systems and service monitoring system. It collects metrics from configured targets at given intervals, evaluates rule expressions, displays the results, and can trigger alerts if some condition is observed to be true.

About Grafana :

Grafana is an open source visualization tool that can be used on top of a variety of different data stores but is most commonly used together with Graphite, InfluxDB, Prometheus, Elasticsearch and Logz.io.

Step 1 :

First we have to create Persistent Volume for the Prometheus.

Step 2 :

Then we have to creating service for exporting the Prometheus.

Step 3 :

Afterwards we have to create Deployment for the Prometheus.

Step 4 :

Same for grafana also we have tobcreate Persistent Volume.

Step 5 :

Now we have to create Service for exporting Grafana.

Step 6 :

And create also a Deployment for Grafana.

Step 7 :

And in the last we also have to create a kustomization file for the pod containing both Prometheus and Grafana.

We can start the Prometheus and Grafana services with the following Command.

kubectl apply -k 

Now we can able to access web UI our Prometheus.

And same for the Grafana also we can able to access web UI.

Here we are at the end of the task.

Thanks for reading.

--

--