@leverege/build-tools 2.55.0 → 2.55.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +2 -2
- package/src/helm-charts/prom-operator/helmdn.plugin +2 -2
- package/src/helm-charts/prom-operator/prometheus-stack.yaml.ovh +1 -3
- package/src/helm-charts/prom-operator/rules/test-alert.yaml +18 -0
- package/src/helm-charts/prom-operator/stackdriver-exporter.yaml.ovh +6 -1
- package/src/helm-charts/redis/helmup.plugin +1 -1
- package/src/helm-charts/redis/redis-local.yaml +5 -0
- package/src/helm-charts/traefik/helmup.plugin +2 -2
- package/src/helm-charts/prom-operator/rules/kubernetes-rules.yaml.off +0 -112
- package/src/helm-charts/prom-operator/rules/prometheus-rules.yaml.off +0 -79
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@leverege/build-tools",
|
|
3
|
-
"version": "2.55.
|
|
3
|
+
"version": "2.55.1",
|
|
4
4
|
"description": "A collection of build / support tools for Leverege developers",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"repository": {
|
|
@@ -66,7 +66,7 @@
|
|
|
66
66
|
"execa": "^9.4.1",
|
|
67
67
|
"glob": "^11.0.0",
|
|
68
68
|
"handlebars": "^4.7.8",
|
|
69
|
-
"inquirer": "^12.0.
|
|
69
|
+
"inquirer": "^12.0.1",
|
|
70
70
|
"js-yaml": "^4.1.0",
|
|
71
71
|
"ms": "^2.1.3",
|
|
72
72
|
"npm-registry-fetch": "^18.0.2",
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
#!/bin/bash
|
|
2
2
|
#
|
|
3
3
|
# This will uninstall of the the operator components...
|
|
4
|
-
helm uninstall -n prometheus elasticsearch8-exporter stackdriver-exporter
|
|
5
|
-
|
|
4
|
+
helm uninstall -n prometheus prometheus-stack elasticsearch8-exporter stackdriver-exporter
|
|
5
|
+
|
|
6
6
|
# including all CRDs and configs
|
|
7
7
|
kubectl delete crd \
|
|
8
8
|
alertmanagerconfigs.monitoring.coreos.com \
|
|
@@ -14,7 +14,7 @@ defaultRules:
|
|
|
14
14
|
kubeApiserver: true # GPT Keep an eye on API server availability
|
|
15
15
|
kubeApiserverAvailability: false
|
|
16
16
|
kubeApiserverSlos: false
|
|
17
|
-
kubelet:
|
|
17
|
+
kubelet: true # GPT Consider monitoring kubelet status, especially on scaled nodes
|
|
18
18
|
kubeProxy: false
|
|
19
19
|
kubePrometheusGeneral: false
|
|
20
20
|
kubePrometheusNodeRecording: false
|
|
@@ -37,8 +37,6 @@ prometheus:
|
|
|
37
37
|
ruleSelectorNilUsesHelmValues: false
|
|
38
38
|
serviceMonitorSelectorNilUsesHelmValues: false
|
|
39
39
|
probeSelectorNilUsesHelmValues: false
|
|
40
|
-
#nodeSelector:
|
|
41
|
-
#workload: monitor
|
|
42
40
|
|
|
43
41
|
# default is using kube-dns which is usually sufficient for our needs but
|
|
44
42
|
# can be switched over to CoreDNS if the need arises
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
apiVersion: monitoring.coreos.com/v1
|
|
2
|
+
kind: PrometheusRule
|
|
3
|
+
metadata:
|
|
4
|
+
name: test-alert
|
|
5
|
+
namespace: prometheus # Ensure this matches your Prometheus namespace
|
|
6
|
+
spec:
|
|
7
|
+
groups:
|
|
8
|
+
- name: test.rules
|
|
9
|
+
rules:
|
|
10
|
+
- alert: TestAlert
|
|
11
|
+
expr: vector(1) # This will always be true, triggering the alert
|
|
12
|
+
for: 1m # Alert if condition is true for 1 minute
|
|
13
|
+
labels:
|
|
14
|
+
severity: warning
|
|
15
|
+
annotations:
|
|
16
|
+
summary: "Test Alert for Slack"
|
|
17
|
+
description: "This is a test alert to verify the Slack receiver configuration."
|
|
18
|
+
|
|
@@ -13,7 +13,12 @@ stackdriver:
|
|
|
13
13
|
serviceMonitor:
|
|
14
14
|
enabled: true
|
|
15
15
|
namespace: prometheus
|
|
16
|
-
interval:
|
|
16
|
+
interval: "30s"
|
|
17
|
+
relabelings:
|
|
18
|
+
- action: labelmap
|
|
19
|
+
regex: __meta_kubernetes_pod_label_(.+)
|
|
20
|
+
- action: labelmap
|
|
21
|
+
regex: __meta_kubernetes_service_label_(.+)
|
|
17
22
|
|
|
18
23
|
annotations:
|
|
19
24
|
prometheus.io/port: "9255"
|
|
@@ -4,7 +4,7 @@ showInstalling "Redis"
|
|
|
4
4
|
|
|
5
5
|
OCI_CHART="oci://registry-1.docker.io/bitnamicharts/redis"
|
|
6
6
|
|
|
7
|
-
[ -z "$REDIS_CHART_VERSION" ] && REDIS_CHART_VERSION="20.1
|
|
7
|
+
[ -z "$REDIS_CHART_VERSION" ] && REDIS_CHART_VERSION="20.2.1"
|
|
8
8
|
|
|
9
9
|
helm upgrade --install redis $OCI_CHART \
|
|
10
10
|
--values redis/redis-local.yaml \
|
|
@@ -11,13 +11,13 @@
|
|
|
11
11
|
# kubectl apply --namespace traefik --server-side \
|
|
12
12
|
# --force-conflicts -k https://github.com/traefik/traefik-helm-chart/traefik/crds/\?ref\=v27
|
|
13
13
|
#
|
|
14
|
-
showInstalling "Traefik Load Balancer / Router"
|
|
14
|
+
showInstalling "Traefik v3 Load Balancer / Router"
|
|
15
15
|
|
|
16
16
|
TRAEFIK_NAMESPACE="traefik"
|
|
17
17
|
|
|
18
18
|
addHelmRepo traefik https://helm.traefik.io/traefik
|
|
19
19
|
|
|
20
|
-
[ -z "$TRAEFIK_CHART_VERSION" ] && TRAEFIK_CHART_VERSION="
|
|
20
|
+
[ -z "$TRAEFIK_CHART_VERSION" ] && TRAEFIK_CHART_VERSION="32"
|
|
21
21
|
helm upgrade --install traefik traefik/traefik \
|
|
22
22
|
--namespace $TRAEFIK_NAMESPACE --create-namespace \
|
|
23
23
|
--values traefik/traefik-local.yaml \
|
|
@@ -1,112 +0,0 @@
|
|
|
1
|
-
apiVersion: monitoring.coreos.com/v1
|
|
2
|
-
kind: PrometheusRule
|
|
3
|
-
metadata:
|
|
4
|
-
name: kubernetes-rules
|
|
5
|
-
namespace: prometheus
|
|
6
|
-
|
|
7
|
-
spec:
|
|
8
|
-
groups:
|
|
9
|
-
- name: Kubernetes
|
|
10
|
-
rules:
|
|
11
|
-
- alert: KubernetesNodeNotReady
|
|
12
|
-
expr: kube_node_status_condition{condition="Ready",status="true"} == 0
|
|
13
|
-
for: 5m
|
|
14
|
-
labels:
|
|
15
|
-
severity: page
|
|
16
|
-
priority: P3
|
|
17
|
-
annotations:
|
|
18
|
-
summary: "Kubernetes Node is not ready"
|
|
19
|
-
description: "Node {{ $labels.node }} is stuck in unready state for more than 5m"
|
|
20
|
-
dashboard: "Check GKE or EKS node status"
|
|
21
|
-
|
|
22
|
-
- alert: KubernetesMemoryPressure
|
|
23
|
-
expr: kube_node_status_condition{condition="MemoryPressure",status="true"} == 1
|
|
24
|
-
for: 5m
|
|
25
|
-
labels:
|
|
26
|
-
severity: error
|
|
27
|
-
annotations:
|
|
28
|
-
summary: "Kubernetes memory pressure"
|
|
29
|
-
description: "{{ $labels.node }} has a MemoryPressure condition"
|
|
30
|
-
dashboard: "Check GKE or EKS node status"
|
|
31
|
-
|
|
32
|
-
- alert: KubernetesDiskPressure
|
|
33
|
-
expr: kube_node_status_condition{condition="DiskPressure",status="true"} == 1
|
|
34
|
-
for: 5m
|
|
35
|
-
labels:
|
|
36
|
-
severity: error
|
|
37
|
-
annotations:
|
|
38
|
-
summary: "Kubernetes disk pressure"
|
|
39
|
-
description: "{{ $labels.node }} has DiskPressure condition"
|
|
40
|
-
dashboard: "Check GKE or EKS node status"
|
|
41
|
-
|
|
42
|
-
- alert: KubernetesOutOfDisk
|
|
43
|
-
expr: kube_node_status_condition{condition="OutOfDisk",status="true"} == 1
|
|
44
|
-
for: 5m
|
|
45
|
-
labels:
|
|
46
|
-
severity: error
|
|
47
|
-
annotations:
|
|
48
|
-
summary: "Kubernetes out of disk"
|
|
49
|
-
description: "{{ $labels.node }} has is out of disk space"
|
|
50
|
-
dashboard: "Check GKE or EKS node status"
|
|
51
|
-
|
|
52
|
-
- alert: KubernetesVolumeOutOfDiskSpace
|
|
53
|
-
expr: kubelet_volume_stats_available_bytes / kubelet_volume_stats_capacity_bytes * 100 < 10
|
|
54
|
-
for: 5m
|
|
55
|
-
labels:
|
|
56
|
-
severity: error
|
|
57
|
-
priority: P2
|
|
58
|
-
annotations:
|
|
59
|
-
summary: "Kubernetes PVC Free Space < 10%"
|
|
60
|
-
description: "PVC volume {{ $labels.persistentvolumeclaim }} is almost full - down to {{ $value | humanize }}% available"
|
|
61
|
-
dashboard: "OVH:<MONITORING>/k8s-pvc/pvc-usage?var-volume={{ $labels.persistentvolumeclaim }}"
|
|
62
|
-
|
|
63
|
-
# - alert: KubernetesVolumeFullInFourDays
|
|
64
|
-
# expr: predict_linear(kubelet_volume_stats_available_bytes[6h], 4 * 24 * 3600) < 0
|
|
65
|
-
# for: 5m
|
|
66
|
-
# labels:
|
|
67
|
-
# severity: error
|
|
68
|
-
# annotations:
|
|
69
|
-
# summary: "Kubernetes Volume full in four days "
|
|
70
|
-
# description: "{{ $labels.namespace }}/{{ $labels.persistentvolumeclaim }} is expected to fill up within four days. Currently {{ $value | humanize }}% is available."
|
|
71
|
-
# dashboard: "OVH:<MONITORING>/pvc"
|
|
72
|
-
|
|
73
|
-
- alert: KubernetesPersistentvolumeError
|
|
74
|
-
expr: kube_persistentvolume_status_phase{phase=~"Failed|Pending",job="kube-state-metrics"} > 0
|
|
75
|
-
for: 5m
|
|
76
|
-
labels:
|
|
77
|
-
severity: error
|
|
78
|
-
annotations:
|
|
79
|
-
summary: "Kubernetes PersistentVolume error "
|
|
80
|
-
description: "PersistentVolumeClaim {{ $labels.namespace }}/{{ $labels.persistentvolumeclaim }} is stuck pending"
|
|
81
|
-
dashboard: "Check GKE or EKS PVC/storage status"
|
|
82
|
-
|
|
83
|
-
- alert: KubernetesHpaScaleCapability
|
|
84
|
-
expr: kube_hpa_status_desired_replicas >= kube_hpa_spec_max_replicas
|
|
85
|
-
for: 15m
|
|
86
|
-
labels:
|
|
87
|
-
severity: warning
|
|
88
|
-
annotations:
|
|
89
|
-
summary: "Kubernetes HPA scale capability"
|
|
90
|
-
description: "Kubernetes has scaled {{ $labels.hpa }} to max number of scaled pods."
|
|
91
|
-
dashboard: "OVH:<MONITORING>/k8-deployment"
|
|
92
|
-
|
|
93
|
-
- alert: KubernetesPodNotHealthy
|
|
94
|
-
expr: kube_pod_status_phase{phase=~"Pending|Unknown|Failed"} == 1
|
|
95
|
-
for: 20m
|
|
96
|
-
labels:
|
|
97
|
-
severity: error
|
|
98
|
-
annotations:
|
|
99
|
-
summary: "Kubernetes Pod not healthy"
|
|
100
|
-
description: "Pod {{ $labels.pod }} has been in a non-ready state for longer than 20 minutes."
|
|
101
|
-
dashboard: "Check the pod status using the Kubernetes UI"
|
|
102
|
-
|
|
103
|
-
- alert: KubernetesPodCrashLooping
|
|
104
|
-
expr: rate(kube_pod_container_status_restarts_total[15m]) * 60 * 5 > 5
|
|
105
|
-
for: 5m
|
|
106
|
-
labels:
|
|
107
|
-
severity: page
|
|
108
|
-
priority: P2
|
|
109
|
-
annotations:
|
|
110
|
-
summary: "Kubernetes pod crash looping"
|
|
111
|
-
description: "{{ $labels.pod }} is in a crash loop"
|
|
112
|
-
dashboard: "Check the pod status using the Kubernetes UI"
|
|
@@ -1,79 +0,0 @@
|
|
|
1
|
-
apiVersion: monitoring.coreos.com/v1
|
|
2
|
-
kind: PrometheusRule
|
|
3
|
-
metadata:
|
|
4
|
-
name: prometheus-rules
|
|
5
|
-
namespace: prometheus
|
|
6
|
-
|
|
7
|
-
spec:
|
|
8
|
-
groups:
|
|
9
|
-
- name: Prometheus
|
|
10
|
-
rules:
|
|
11
|
-
- alert: targets_down
|
|
12
|
-
expr: up{target_env!="preemptibles"} == 0
|
|
13
|
-
for: 10m
|
|
14
|
-
labels:
|
|
15
|
-
severity: warning
|
|
16
|
-
annotations:
|
|
17
|
-
summary: Prometheus target missing
|
|
18
|
-
description: "Prometheus failed to scrape {{ $labels.app }}"
|
|
19
|
-
dashboard: "See prometheus.md in SRE Playbook"
|
|
20
|
-
|
|
21
|
-
- alert: PrometheusConfigurationReloadFailure
|
|
22
|
-
expr: prometheus_config_last_reload_successful != 1
|
|
23
|
-
for: 5m
|
|
24
|
-
labels:
|
|
25
|
-
severity: warning
|
|
26
|
-
annotations:
|
|
27
|
-
summary: "Prometheus server configuration reload failure"
|
|
28
|
-
description: "Prometheus server failed to reload server configs (e.g. alerts, rules)"
|
|
29
|
-
dashboard: "See prometheus.md in SRE Playbook"
|
|
30
|
-
|
|
31
|
-
- alert: PrometheusAlertmanagerConfigurationReloadFailure
|
|
32
|
-
expr: alertmanager_config_last_reload_successful != 1
|
|
33
|
-
for: 5m
|
|
34
|
-
labels:
|
|
35
|
-
severity: warning
|
|
36
|
-
annotations:
|
|
37
|
-
summary: "Prometheus AlertManager configuration reload failure"
|
|
38
|
-
description: "AlertManager failed to reload alert configs (e.g. slack, opsgenie)"
|
|
39
|
-
dashboard: "See prometheus.md in SRE Playbook"
|
|
40
|
-
|
|
41
|
-
- alert: PrometheusTooManyRestarts
|
|
42
|
-
expr: changes(process_start_time_seconds{job=~"prometheus|alertmanager"}[15m]) > 2
|
|
43
|
-
for: 5m
|
|
44
|
-
labels:
|
|
45
|
-
severity: warning
|
|
46
|
-
annotations:
|
|
47
|
-
summary: "Prometheus is in a crash loop"
|
|
48
|
-
description: "Prometheus {{ $labels.component }} has restarted more than twice in the last 15 minutes. It might be crashlooping."
|
|
49
|
-
dashboard: "See prometheus.md in SRE Playbook"
|
|
50
|
-
|
|
51
|
-
- alert: PrometheusNotConnectedToAlertmanager
|
|
52
|
-
expr: prometheus_notifications_alertmanagers_discovered < 1
|
|
53
|
-
for: 5m
|
|
54
|
-
labels:
|
|
55
|
-
severity: error
|
|
56
|
-
annotations:
|
|
57
|
-
summary: "Prometheus not connected to alertmanager"
|
|
58
|
-
description: "Prometheus cannot connect the alertmanager - new alerts may not be detected"
|
|
59
|
-
dashboard: "See prometheus.md in SRE Playbook"
|
|
60
|
-
|
|
61
|
-
- alert: PrometheusNotificationsBacklog
|
|
62
|
-
expr: min_over_time(prometheus_notifications_queue_length[10m]) > 0
|
|
63
|
-
for: 5m
|
|
64
|
-
labels:
|
|
65
|
-
severity: warning
|
|
66
|
-
annotations:
|
|
67
|
-
summary: "Prometheus notifications backlog"
|
|
68
|
-
description: "The Prometheus notification queue has not been empty for 10 minutes"
|
|
69
|
-
dashboard: "See prometheus.md in SRE Playbook"
|
|
70
|
-
|
|
71
|
-
- alert: PrometheusAlertmanagerNotificationFailing
|
|
72
|
-
expr: rate(alertmanager_notifications_failed_total[1m]) > 0
|
|
73
|
-
for: 5m
|
|
74
|
-
labels:
|
|
75
|
-
severity: error
|
|
76
|
-
annotations:
|
|
77
|
-
summary: "Prometheus AlertManager notification failing"
|
|
78
|
-
description: "Alertmanager is failing to send notifications"
|
|
79
|
-
dashboard: "See prometheus.md in SRE Playbook"
|