feat: add observability stack to gitops (kube-prom-stack, loki, helm-dashboard, blackbox-exporter)

This commit is contained in:
2026-04-29 13:33:35 +02:00
parent befea76e7e
commit 86feb58574
7 changed files with 209 additions and 0 deletions
@@ -0,0 +1,14 @@
dashboard:
persistence:
size: 100M
storageClassName: ceph-rbd
ingress:
enabled: true
className: public
annotations: {}
hosts:
- host: helm.alexandre-vazquez.cloud
paths:
- path: /
pathType: ImplementationSpecific
@@ -0,0 +1,72 @@
grafana:
additionalDataSources:
- name: loki
type: loki
url: http://loki.observability.svc.cluster.local:3100
ingress:
enabled: true
ingressClassName: public
hosts:
- grafana.alexandre-vazquez.cloud
annotations:
external-dns.alpha.kubernetes.io/hostname: grafana.alexandre-vazquez.internal
additionalIngresses:
- name: grafana-ingress-internal
ingressClassName: public
hosts:
- grafana.alexandre-vazquez.internal
annotations:
external-dns.alpha.kubernetes.io/hostname: grafana.alexandre-vazquez.internal
kubeApiServer:
serviceMonitor:
metricRelabelings:
- action: drop
sourceLabels: [__name__]
regex: apiserver_request_duration_seconds_bucket|apiserver_request_sli_duration_seconds_bucket|apiserver_request_body_size_bytes_bucket|apiserver_response_sizes_bucket|apiserver_watch_list_duration_seconds_bucket|apiserver_watch_cache_read_wait_seconds_bucket|apiserver_watch_events_sizes_bucket|apiserver_admission_controller_admission_duration_seconds_bucket|apiserver_admission_webhook_admission_duration_seconds_bucket|apiserver_flowcontrol_request_execution_seconds_bucket|apiserver_flowcontrol_request_wait_duration_seconds_bucket
kubeControllerManager:
endpoints:
- 192.168.1.40
serviceMonitor:
metricRelabelings:
- action: drop
sourceLabels: [__name__]
regex: workqueue_queue_duration_seconds_bucket|workqueue_work_duration_seconds_bucket|storage_operation_duration_seconds_bucket|rest_client_request_duration_seconds_bucket
kubeEtcd:
serviceMonitor:
metricRelabelings:
- action: drop
sourceLabels: [__name__]
regex: etcd_request_duration_seconds_bucket|etcd_disk_backend_commit_duration_seconds_bucket|etcd_disk_wal_fsync_duration_seconds_bucket|etcd_network_peer_round_trip_time_seconds_bucket
kubeScheduler:
endpoints:
- 192.168.1.40
serviceMonitor:
metricRelabelings:
- action: drop
sourceLabels: [__name__]
regex: scheduler_plugin_execution_duration_seconds_bucket|scheduler_scheduling_algorithm_duration_seconds_bucket|scheduler_pod_scheduling_duration_seconds_bucket|scheduler_framework_extension_point_duration_seconds_bucket
kubelet:
serviceMonitor:
metricRelabelings:
- action: drop
sourceLabels: [__name__]
regex: storage_operation_duration_seconds_bucket|rest_client_request_duration_seconds_bucket|kubelet_runtime_operations_duration_seconds_bucket|kubelet_cgroup_manager_duration_seconds_bucket|kubelet_pod_start_duration_seconds_bucket|kubelet_pod_worker_duration_seconds_bucket
prometheus:
prometheusSpec:
evaluationInterval: 60s
scrapeInterval: 60s
storageSpec:
volumeClaimTemplate:
spec:
accessModes:
- ReadWriteOnce
storageClassName: ceph-rbd
resources:
requests:
storage: 20Gi
+10
View File
@@ -0,0 +1,10 @@
grafana:
sidecar:
datasources:
enabled: false
loki:
persistence:
enabled: true
size: 10Gi
storageClassName: ceph-rbd
@@ -0,0 +1,20 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: blackbox-exporter
namespace: argocd
spec:
project: default
source:
repoURL: https://prometheus-community.github.io/helm-charts
chart: prometheus-blackbox-exporter
targetRevision: 11.0.0
helm:
releaseName: blackbox-exporter
destination:
server: https://kubernetes.default.svc
namespace: observability
syncPolicy:
syncOptions:
- CreateNamespace=true
- ServerSideApply=true
+25
View File
@@ -0,0 +1,25 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: helm-dashboard
namespace: argocd
spec:
project: default
sources:
- repoURL: https://helm-charts.komodor.io
chart: helm-dashboard
targetRevision: 2.0.6
helm:
releaseName: helm-dashboard
valueFiles:
- $values/apps/observability/helm-dashboard-values.yaml
- repoURL: https://gitea.alexandre-vazquez.cloud/baphemot/gitops.git
targetRevision: HEAD
ref: values
destination:
server: https://kubernetes.default.svc
namespace: observability
syncPolicy:
syncOptions:
- CreateNamespace=true
- ServerSideApply=true
+41
View File
@@ -0,0 +1,41 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: kube-prom-stack
namespace: argocd
annotations:
argocd.argoproj.io/sync-wave: "1"
spec:
project: default
sources:
- repoURL: https://prometheus-community.github.io/helm-charts
chart: kube-prometheus-stack
targetRevision: 45.5.0
helm:
releaseName: kube-prom-stack
valueFiles:
- $values/apps/observability/kube-prom-stack-values.yaml
- repoURL: https://gitea.alexandre-vazquez.cloud/baphemot/gitops.git
targetRevision: HEAD
ref: values
destination:
server: https://kubernetes.default.svc
namespace: observability
ignoreDifferences:
- group: admissionregistration.k8s.io
kind: MutatingWebhookConfiguration
jqPathExpressions:
- .webhooks[].clientConfig.caBundle
- group: admissionregistration.k8s.io
kind: ValidatingWebhookConfiguration
jqPathExpressions:
- .webhooks[].clientConfig.caBundle
- group: apiextensions.k8s.io
kind: CustomResourceDefinition
jqPathExpressions:
- .spec.conversion.webhook.clientConfig.caBundle
syncPolicy:
syncOptions:
- CreateNamespace=true
- ServerSideApply=true
- RespectIgnoreDifferences=true
+27
View File
@@ -0,0 +1,27 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: loki
namespace: argocd
annotations:
argocd.argoproj.io/sync-wave: "2"
spec:
project: default
sources:
- repoURL: https://grafana.github.io/helm-charts
chart: loki-stack
targetRevision: 2.9.9
helm:
releaseName: loki
valueFiles:
- $values/apps/observability/loki-values.yaml
- repoURL: https://gitea.alexandre-vazquez.cloud/baphemot/gitops.git
targetRevision: HEAD
ref: values
destination:
server: https://kubernetes.default.svc
namespace: observability
syncPolicy:
syncOptions:
- CreateNamespace=true
- ServerSideApply=true