Merge pull request #10583 from sathieu/helm_prometheusrule_labels_annotations

helm: add labels and annotations to PrometheusRule
This commit is contained in:
Travis Nielsen
2022-07-25 13:08:23 -06:00
committed by GitHub
3 changed files with 29 additions and 16 deletions
+18 -16
View File
@@ -52,22 +52,24 @@ helm install --create-namespace --namespace rook-ceph rook-ceph-cluster \
The following tables lists the configurable parameters of the rook-operator chart and their default values.
| Parameter | Description | Default |
| ---------------------------------- | ------------------------------------------------------------------------------------------ | --------------- |
| `operatorNamespace` | Namespace of the Rook Operator | `rook-ceph` |
| `kubeVersion` | Optional override of the target kubernetes version | `` |
| `configOverride` | Cluster ceph.conf override | `<none>` |
| `toolbox.enabled` | Enable Ceph debugging pod deployment. See [toolbox](../Troubleshooting/ceph-toolbox.md) | `false` |
| `toolbox.tolerations` | Toolbox tolerations | `[]` |
| `toolbox.affinity` | Toolbox affinity | `{}` |
| `toolbox.resources` | Toolbox resources | see values.yaml |
| `monitoring.enabled` | Enable Prometheus integration, will also create necessary RBAC rules | `false` |
| `monitoring.createPrometheusRules` | Whether to create the Prometheus rules for Ceph alerts | `false` |
| `cephClusterSpec.*` | Cluster configuration, see below | See below |
| `ingress.dashboard` | Enable an ingress for the ceph-dashboard | `{}` |
| `cephBlockPools.[*]` | A list of CephBlockPool configurations to deploy | See below |
| `cephFileSystems.[*]` | A list of CephFileSystem configurations to deploy | See below |
| `cephObjectStores.[*]` | A list of CephObjectStore configurations to deploy | See below |
| Parameter | Description | Default |
| --------------------------------------- | ------------------------------------------------------------------------------------------ | --------------- |
| `operatorNamespace` | Namespace of the Rook Operator | `rook-ceph` |
| `kubeVersion` | Optional override of the target kubernetes version | `` |
| `configOverride` | Cluster ceph.conf override | `<none>` |
| `toolbox.enabled` | Enable Ceph debugging pod deployment. See [toolbox](../Troubleshooting/ceph-toolbox.md) | `false` |
| `toolbox.tolerations` | Toolbox tolerations | `[]` |
| `toolbox.affinity` | Toolbox affinity | `{}` |
| `toolbox.resources` | Toolbox resources | see values.yaml |
| `monitoring.enabled` | Enable Prometheus integration, will also create necessary RBAC rules | `false` |
| `monitoring.createPrometheusRules` | Whether to create the Prometheus rules for Ceph alerts | `false` |
| `monitoring.prometheusRule.labels` | Labels applied to PrometheusRule | `false` |
| `monitoring.prometheusRule.annotations` | Annotations applied to PrometheusRule | `false` |
| `cephClusterSpec.*` | Cluster configuration, see below | See below |
| `ingress.dashboard` | Enable an ingress for the ceph-dashboard | `{}` |
| `cephBlockPools.[*]` | A list of CephBlockPool configurations to deploy | See below |
| `cephFileSystems.[*]` | A list of CephFileSystem configurations to deploy | See below |
| `cephObjectStores.[*]` | A list of CephObjectStore configurations to deploy | See below |
### **Ceph Cluster Spec**
@@ -7,6 +7,13 @@ metadata:
labels:
prometheus: rook-prometheus
role: alert-rules
{{- if .Values.monitoring.prometheusRule.labels }}
{{ toYaml .Values.monitoring.prometheusRule.labels | indent 4 }}
{{- end }}
{{- if .Values.monitoring.prometheusRule.annotations }}
annotations:
{{ toYaml .Values.monitoring.prometheusRule.annotations | indent 4 }}
{{- end }}
name: prometheus-ceph-rules
namespace: {{ default .Release.Namespace .Values.monitoring.rulesNamespaceOverride }}
spec:
@@ -47,6 +47,10 @@ monitoring:
# Monitoring settings for external clusters:
# externalMgrEndpoints: <list of endpoints>
# externalMgrPrometheusPort: <port>
# allow adding custom labels and annotations to the prometheus rule
prometheusRule:
labels: {}
annotations: {}
# If true, create & use PSP resources. Set this to the same value as the rook-ceph chart.
pspEnable: true