Skip to content

Commit

Permalink
Add alert to monitor KubeadmConfig
Browse files Browse the repository at this point in the history
  • Loading branch information
fiunchinho committed Nov 28, 2024
1 parent 97c68f6 commit 824789f
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 0 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Added

- Add alert to monitor the `KubeadmConfig` CRs having trouble generating bootstrap data.

## [4.26.2] - 2024-11-27

### Changed
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{{- if eq .Values.managementCluster.provider.flavor "capi" }}
apiVersion: monitoring.coreos.com/v1
kind: PrometheusRule
metadata:
labels: {{- include "labels.common" . | nindent 4}}
name: capi-kubeadmconfig.rules
namespace: {{.Values.namespace}}
spec:
groups:
- name: capi-kubeadmconfig
rules:
- alert: KubeadmConfigDataSecretNotAvailable
expr: capi_kubeadmconfig_status_condition{type="DataSecretAvailable", status="False"} > 0
for: 1h
labels:
area: kaas
cancel_if_monitoring_agent_down: "true"
cancel_if_outside_working_hours: "true"
severity: page
team: {{ include "providerTeam" . }}
topic: managementcluster
annotations:
description: |-
{{`KubeadmConfig {{$labels.exported_namespace}}/{{$labels.name}} in cluster {{$labels.cluster_name}} encountered errors while generating a data secret`}}
opsrecipe: capi-kubeadmconfig/
{{- end }}

0 comments on commit 824789f

Please sign in to comment.