diff --git a/_topic_maps/_topic_map.yml b/_topic_maps/_topic_map.yml index 172d13fe6077..b365ccd0098a 100644 --- a/_topic_maps/_topic_map.yml +++ b/_topic_maps/_topic_map.yml @@ -192,6 +192,8 @@ Topics: File: managing-preview-features - Name: Configuring and integrating the RHACS plugin with Red Hat Developer Hub File: configuring-and-integrating-the-rhacs-plugin-with-red-hat-developer-hub +- Name: Configuring Custom Prometheus metrics + File: configure-custom-prometheus-metrics --- Name: Operating Dir: operating diff --git a/configuration/configure-custom-prometheus-metrics.adoc b/configuration/configure-custom-prometheus-metrics.adoc new file mode 100644 index 000000000000..4588a49e1736 --- /dev/null +++ b/configuration/configure-custom-prometheus-metrics.adoc @@ -0,0 +1,48 @@ +[id="configure-custom-prometheus-metrics"] += Configuring custom Prometheus metrics +include::modules/common-attributes.adoc[] +:context: configure-custom-prometheus-metrics + +toc::[] + +[role="_abstract"] +With {product-title}, you can enable some Prometheus metrics to be exposed on the `/metrics` path of the central API endpoint. + +The available metric categories include: + +* Image vulnerabilities. + +Each category is configured with a data gathering period and a list of metrics. A metric is associated with a set of labels. + +[NOTE] +==== +The `/metrics` path is accessible for API tokens with Administration resource view permissions. The values of the labels are subject to Scoped Access Control. +==== + +The currently enabled metrics, if any, are shown on the *System Configuration* page of the *Platform Configuration* section of the {product-title} UI. In edit mode, the UI allows you to enable or disable one of the predefined metrics. + +The `/v1/config` API allows for configuring metrics with custom metric names and a custom set of labels. + +Accepted image vulnerability labels: + +* Cluster +* Namespace +* Deployment +* IsPlatformWorkload +* ImageID +* ImageRegistry +* ImageRemote +* ImageTag +* Component +* ComponentVersion +* OperatingSystem +* CVE +* CVSS +* Severity +* SeverityV2 +* SeverityV3 +* IsFixable + +[role="_additional-resources"] +.Additional resources +* xref:modules/rbac-resource-definitions.adoc[Resource definitions]