If you plan to follow along with this article, please be sure to check out how to deploy prometheus operator in one minute first.
I am a big fan of Prometheus for gathering application and infrastructure metrics. Prometheus has helped me troubleshoot problems many times at my day job. If Prometheus has any drawbacks, it is that it’s configuration can be fairly involved. However, if you are currently using Kubernetes, you can take advantage of Prometheus Operator to simplify the deployment of Prometheus. In fact, Prometheus Operator itself is very easy to deploy. Try it for yourself with the following command.
curl https://raw.githubusercontent.com/coreos/prometheus-operator/master/bundle.yaml \
-o prometheus-operator.yml \
&& kubectl apply -f prometheus-operator.yml
What’s next? Check out custom prometheus configs with prometheus operator.