diff --git a/cilium-enterprise-mixin/alerts/ciliumAlerts.libsonnet b/cilium-enterprise-mixin/alerts/ciliumAlerts.libsonnet index bc0ef91ac..5adebe484 100644 --- a/cilium-enterprise-mixin/alerts/ciliumAlerts.libsonnet +++ b/cilium-enterprise-mixin/alerts/ciliumAlerts.libsonnet @@ -272,6 +272,76 @@ }, ], }, + { + name: 'Cilium Clustermesh', + rules: [ + { + alert: 'CiliumAgentRemoteClusterNotReady', + expr: 'count(cilium_clustermesh_remote_cluster_readiness_status < 1) by (%s) > 0' % std.join(', ', (['source_cluster', 'target_cluster'] + $._config.alertAggregationLabels)), + labels: { + severity: 'critical', + }, + annotations: { + summary: "Agent can't mesh with remote cluster.", + description: "Agent can't mesh with {{$labels.target_cluster}}", + }, + 'for': '5m', + }, + { + alert: 'CiliumAgentRemoteClusterFailing', + expr: 'sum(rate(cilium_clustermesh_remote_cluster_failures[5m])) by (%s) > 0' % std.join(', ', (['source_cluster', 'target_cluster'] + $._config.alertAggregationLabels)), + labels: { + severity: 'critical', + }, + annotations: { + summary: 'Agent fails to mesh with remote cluster.', + description: 'Agent fails to mesh with {{$labels.target_cluster}}', + }, + 'for': '5m', + }, + ], + }, + { + name: 'Cilium Kvstoremesh', + rules: [ + { + alert: 'CiliumKvstoremeshRemoteClusterNotReady', + expr: 'count(cilium_kvstoremesh_remote_cluster_readiness_status < 1) by (%s) > 0' % std.join(', ', (['source_cluster', 'target_cluster'] + $._config.alertAggregationLabels)), + labels: { + severity: 'critical', + }, + annotations: { + summary: "Kvstoremesh can't mesh with remote cluster.", + description: "Kvstoremesh can't mesh with {{$labels.target_cluster}}", + }, + 'for': '5m', + }, + { + alert: 'CiliumKvstoremeshRemoteClusterFailing', + expr: 'sum(rate(cilium_kvstoremesh_remote_cluster_failures[5m])) by (%s) > 0' % std.join(', ', (['source_cluster', 'target_cluster'] + $._config.alertAggregationLabels)), + labels: { + severity: 'critical', + }, + annotations: { + summary: 'Kvstoremesh fails to mesh with remote cluster.', + description: 'Kvstoremesh fails to mesh with {{$labels.target_cluster}}', + }, + 'for': '5m', + }, + { + alert: 'CiliumKvstoremeshErrors', + expr: 'sum(rate(cilium_kvstoremesh_kvstore_sync_errors_total[5m])) by (%s) > 0' % std.join(', ', (['source_cluster'] + $._config.alertAggregationLabels)), + labels: { + severity: 'critical', + }, + annotations: { + summary: 'Kvstoremesh fails to mesh with remote cluster.', + description: 'Kvstoremesh fails to mesh with {{$labels.target_cluster}}', + }, + 'for': '5m', + }, + ], + }, ], }, } diff --git a/cilium-enterprise-mixin/jsonnetfile.json b/cilium-enterprise-mixin/jsonnetfile.json new file mode 100644 index 000000000..b46345153 --- /dev/null +++ b/cilium-enterprise-mixin/jsonnetfile.json @@ -0,0 +1,6 @@ +{ + "version": 1, + "dependencies": [], + "legacyImports": false +} +