Skip to content

Commit

Permalink
Merge branch 'main' into fix-opsrecipe-test
Browse files Browse the repository at this point in the history
  • Loading branch information
QuentinBisson authored Jun 6, 2024
2 parents 38ffef0 + d36539e commit 7307260
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 11 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Fix and improve the ops-recipe test script.
- Fix cabbage alerts for multi-provider wcs.
- Fix shield alert area labels.
- Fix `cert-exporter` alerting.

### Removed

Expand Down
8 changes: 0 additions & 8 deletions helm/prometheus-rules/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -45,14 +45,6 @@ phoenix
{{- end -}}
{{- end -}}

{{- define "isCertExporterInstalled" -}}
{{- if has .Values.managementCluster.provider.kind (list "cloud-director" "vsphere" "capa") -}}
false
{{- else -}}
true
{{- end -}}
{{- end -}}

{{- define "isBastionBeingMonitored" -}}
{{ not (eq .Values.managementCluster.provider.flavor "capi") }}
{{- end -}}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
{{- if eq (include "isCertExporterInstalled" .) "true" }}
apiVersion: monitoring.coreos.com/v1
kind: PrometheusRule
metadata:
Expand Down Expand Up @@ -31,7 +30,7 @@ spec:
annotations:
description: '{{`Certificate metrics are missing for cluster {{ $labels.cluster_id }}.`}}'
opsrecipe: absent-metrics
expr: max(up{cluster_id!="", cluster_type="workload_cluster"}) by (cluster_id) unless on (cluster_id) count (cert_exporter_not_after{cluster_type="workload_cluster"}) by (cluster_id) > 0
expr: max(up{cluster_id!="", cluster_type="workload_cluster"}) by (cluster_id, installation, pipeline, provider) unless on (cluster_id) count (cert_exporter_not_after{cluster_type="workload_cluster"}) by (cluster_id, installation, pipeline, provider) > 0
for: 30m
labels:
area: kaas
Expand All @@ -42,4 +41,3 @@ spec:
severity: page
team: {{ include "providerTeam" . }}
topic: security
{{- end -}}

0 comments on commit 7307260

Please sign in to comment.