Docs: Improve formatting in monitoring.md. (#13241)

Co-authored-by: Dezhi Wu <hi@5xx.io>
This commit is contained in:
k8s-infra-cherrypick-robot 2025-04-20 04:30:59 -07:00 committed by GitHub
parent 41a861e928
commit 02704ad30c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1,6 +1,7 @@
# Monitoring # Monitoring
Two different methods to install and configure Prometheus and Grafana are described in this doc. Two different methods to install and configure Prometheus and Grafana are described in this doc.
* Prometheus and Grafana installation using Pod Annotations. This installs Prometheus and Grafana in the same namespace as NGINX Ingress * Prometheus and Grafana installation using Pod Annotations. This installs Prometheus and Grafana in the same namespace as NGINX Ingress
* Prometheus and Grafana installation using Service Monitors. This installs Prometheus and Grafana in two different namespaces. This is the preferred method, and helm charts supports this by default. * Prometheus and Grafana installation using Service Monitors. This installs Prometheus and Grafana in two different namespaces. This is the preferred method, and helm charts supports this by default.
@ -15,7 +16,7 @@ This tutorial will show you how to install [Prometheus](https://prometheus.io/)
- The Ingress-Nginx Controller should already be deployed according to the deployment instructions [here](../deploy/index.md). - The Ingress-Nginx Controller should already be deployed according to the deployment instructions [here](../deploy/index.md).
- The controller should be configured for exporting metrics. This requires 3 configurations to the controller. These configurations are : - The controller should be configured for exporting metrics. This requires 3 configurations to the controller. These configurations are:
1. controller.metrics.enabled=true 1. controller.metrics.enabled=true
2. controller.podAnnotations."prometheus.io/scrape"="true" 2. controller.podAnnotations."prometheus.io/scrape"="true"
3. controller.podAnnotations."prometheus.io/port"="10254" 3. controller.podAnnotations."prometheus.io/port"="10254"
@ -74,7 +75,7 @@ This tutorial will show you how to install [Prometheus](https://prometheus.io/)
- name: controller - name: controller
args: args:
.. ..
- '--enable-metrics=true' - '--enable-metrics=true'
ports: ports:
- name: prometheus - name: prometheus
containerPort: 10254 containerPort: 10254