diff --git a/deploy/charts/rook-ceph-cluster/templates/cephcluster.yaml b/deploy/charts/rook-ceph-cluster/templates/cephcluster.yaml index 57babea97..3ff4b6525 100644 --- a/deploy/charts/rook-ceph-cluster/templates/cephcluster.yaml +++ b/deploy/charts/rook-ceph-cluster/templates/cephcluster.yaml @@ -4,6 +4,7 @@ kind: CephCluster metadata: name: {{ default .Release.Namespace .Values.clusterName }} spec: +{{- if .Values.monitoring }} monitoring: enabled: {{ .Values.monitoring.enabled | default false }} {{- if .Values.monitoring.externalMgrEndpoints }} @@ -13,5 +14,6 @@ spec: {{- if .Values.monitoring.externalMgrPrometheusPort }} externalMgrPrometheusPort: {{ toYaml .Values.monitoring.externalMgrPrometheusPort }} {{- end }} +{{- end }} {{ toYaml .Values.cephClusterSpec | indent 2 }} diff --git a/deploy/charts/rook-ceph-cluster/templates/prometheusrules.yaml b/deploy/charts/rook-ceph-cluster/templates/prometheusrules.yaml index 52de90ae4..09768359b 100644 --- a/deploy/charts/rook-ceph-cluster/templates/prometheusrules.yaml +++ b/deploy/charts/rook-ceph-cluster/templates/prometheusrules.yaml @@ -1,3 +1,4 @@ +{{- if .Values.monitoring }} {{- if .Values.monitoring.createPrometheusRules }} --- apiVersion: monitoring.coreos.com/v1 @@ -29,3 +30,4 @@ spec: {{- end }} {{- end }} {{- end }} +{{- end }}