From a6de53ea447cf4c878a35093bffe5dea98a651b4 Mon Sep 17 00:00:00 2001 From: Steve Wilkerson Date: Thu, 11 Jan 2018 09:35:40 -0600 Subject: [PATCH] Export ceph metrics via ceph-mgr prometheus plugin This adds the ability to export ceph metrics via the ceph-mgr prometheus plugin Change-Id: I802712f89cc1bdff20208ee711211dce414e1885 --- ceph/templates/service-mgr.yaml | 5 +++++ ceph/values.yaml | 18 ++++++++++++++++++ 2 files changed, 23 insertions(+) diff --git a/ceph/templates/service-mgr.yaml b/ceph/templates/service-mgr.yaml index e4f7012b83..46e00f5af4 100644 --- a/ceph/templates/service-mgr.yaml +++ b/ceph/templates/service-mgr.yaml @@ -16,6 +16,7 @@ limitations under the License. {{- if .Values.manifests.service_mgr }} {{- $envAll := . }} +{{- $prometheus_annotations := $envAll.Values.monitoring.prometheus.ceph_mgr }} {{- if .Values.deployment.ceph }} {{- if .Values.ceph.enabled.mgr }} --- @@ -23,6 +24,10 @@ apiVersion: v1 kind: Service metadata: name: ceph-mgr + annotations: +{{- if .Values.monitoring.prometheus.enabled }} +{{ tuple $prometheus_annotations | include "helm-toolkit.snippets.prometheus_service_annotations" | indent 4 }} +{{- end }} spec: ports: - port: {{ .Values.network.port.mgr }} diff --git a/ceph/values.yaml b/ceph/values.yaml index 0350700225..d6e98ea91f 100644 --- a/ceph/values.yaml +++ b/ceph/values.yaml @@ -327,6 +327,7 @@ bootstrap: ceph_mgr_enabled_modules: - restful - status + - prometheus # You can configure your mgr modules # below. Each module has its own set @@ -427,7 +428,24 @@ endpoints: port: mon: default: 6789 + ceph_mgr: + namespace: null + hosts: + default: ceph-mgr + host_fqdn_override: + default: null + port: + mgr: + default: 7000 + scheme: + default: http +monitoring: + prometheus: + enabled: true + ceph_mgr: + scrape: true + port: 9283 manifests: configmap_bin_clients: true