Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

allow one missed scan #136

Merged
merged 1 commit into from
Nov 15, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions common/all.yaml.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -186,16 +186,16 @@ groups:
`kubectl --context={{ $labels.kubernetes_cluster }} -n {{ $labels.resource_namespace }} get events`
- alert: KyvernoBackgroundScanCanary
expr: sum by (kubernetes_cluster,resource_namespace,policy_name,rule_name) (increase(kyverno_policy_results_total{rule_name="detect-canary-configmap",rule_execution_cause="background_scan",rule_result="fail"}[1h])) == 0
for: 10m
for: 1h10m
labels:
team: infra
annotations:
summary: "Kyverno background scans canary alert is missing for last 10m"
summary: "Kyverno background scans canary alert is missing for more then 1h"
description: |
Background checks for rule: {{ $labels.rule_name }} of policy: {{ $labels.policy_name }}
is failing to report failures under {{ $labels.resource_namespace }} namespace.
This rule is created to always detect and alert on `kyverno-canary-resource` configmap.

action: |
Following troubleshooting steps might help...
1) check if `kyverno-canary-resource` configmap exits
`kubectl --context={{ $labels.kubernetes_cluster }} -n kube-system get configmap kyverno-canary-resource`
Expand Down